Filter picture

use regular filter picturn in search
This commit is contained in:
Leo Pan 2017-06-16 16:45:21 +08:00 committed by GitHub
parent d469442eae
commit a6b46a3e26

View File

@ -87,6 +87,8 @@ function search (keywords) {
var postTitle = post.title && post.title.trim();
var postContent = post.body && post.body.trim();
var postUrl = post.slug || '';
postContent = postContent.replace(/!\[.*\]\((.+)\)/g,'');
if (postTitle && postContent) {
keywords.forEach(function (keyword, i) {