fix related_posts

This commit is contained in:
xaoxuu 2021-08-25 09:50:40 +08:00
parent 3fc6632a83
commit 43922545ee
1 changed files with 1 additions and 1 deletions

View File

@ -42,7 +42,7 @@ hexo.extend.helper.register('popular_posts_wrapper', function(args){
} else {
list.img = 'https://source.unsplash.com/1280x640/?' + p.cover;
}
} else if (cfg.auto_cover && p.tags.length > 0) {
} else if (cfg.auto_cover && p.tags && p.tags.length > 0) {
var params = '';
p.tags.reverse().forEach((tag, i) => {
if (i > 0) {