Multilingual TODO-fixes, take 1

See #2309
This commit is contained in:
Bjørn Erik Pedersen
2016-08-08 00:12:06 +02:00
parent 0a7d1d0ddc
commit e56ecab157
14 changed files with 34 additions and 105 deletions

View File

@@ -396,24 +396,6 @@ func WordCount(s string) map[string]int {
return m
}
// RemoveSummaryDivider removes summary-divider <!--more--> from content.
// TODO(bep) ml remove
func RemoveSummaryDivider(content []byte) []byte {
b := bytes.Replace(content, summaryDividerAndNewLines, []byte(""), 1)
if len(b) != len(content) {
return b
}
return bytes.Replace(content, SummaryDivider, []byte(""), 1)
}
func removeInternalSummaryDivider(content []byte) []byte {
b := bytes.Replace(content, summaryDividerAndNewLines, []byte(""), 1)
if len(b) != len(content) {
return b
}
return bytes.Replace(content, SummaryDivider, []byte(""), 1)
}
// TruncateWordsByRune truncates words by runes.
func TruncateWordsByRune(words []string, max int) (string, bool) {
count := 0