From bb17d15b2570d6f3303fd4878450a1de7b8b0e8f Mon Sep 17 00:00:00 2001 From: ruibaby Date: Thu, 6 Jun 2019 01:01:12 +0800 Subject: [PATCH] Fixed commentTag variable. --- .../run/halo/app/model/freemarker/tag/CommentTagDirective.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/run/halo/app/model/freemarker/tag/CommentTagDirective.java b/src/main/java/run/halo/app/model/freemarker/tag/CommentTagDirective.java index 8c6b15d01..9b01c571b 100644 --- a/src/main/java/run/halo/app/model/freemarker/tag/CommentTagDirective.java +++ b/src/main/java/run/halo/app/model/freemarker/tag/CommentTagDirective.java @@ -34,7 +34,7 @@ public class CommentTagDirective implements TemplateDirectiveModel { switch (method) { case "latest": int top = Integer.parseInt(params.get("top").toString()); - env.setVariable("categories", builder.build().wrap(postCommentService.pageLatest(top))); + env.setVariable("comments", builder.build().wrap(postCommentService.pageLatest(top))); break; case "count": env.setVariable("count", builder.build().wrap(postCommentService.count()));