This commit is contained in:
deepzz0
2016-10-05 16:39:21 +08:00
parent 70df0b1749
commit 880f0f0c51

2
db.go
View File

@@ -353,7 +353,6 @@ func ManageArchivesArticle(artc *Article, s bool, do string) {
var reg = regexp.MustCompile(setting.Conf.Identifier)
func GenerateExcerptAndRender(artc *Article) {
artc.Content = string(renderPage([]byte(artc.Content)))
index := reg.FindStringIndex(artc.Content)
if len(index) > 0 {
artc.Excerpt = IgnoreHtmlTag(artc.Content[0:index[0]])
@@ -365,6 +364,7 @@ func GenerateExcerptAndRender(artc *Article) {
}
artc.Excerpt = IgnoreHtmlTag(string(uc[0:length]))
}
artc.Content = string(renderPage([]byte(artc.Content)))
}
// 读取草稿箱