fix article desc error

This commit is contained in:
deepzz0
2017-02-11 19:37:51 +08:00
parent d622a8397f
commit ec8297c3f6

1
db.go
View File

@@ -369,6 +369,7 @@ func GenerateExcerptAndRender(artc *Article) {
if strings.HasPrefix(artc.Content, setting.Conf.Description) {
index := strings.Index(artc.Content, "\r\n")
artc.Desc = IgnoreHtmlTag(artc.Content[len(setting.Conf.Description):index])
artc.Content = artc.Content[index:]
}
content := renderPage([]byte(artc.Content))