aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul Duncan <pabs@pablotron.org>2016-03-09 01:18:37 -0500
committerPaul Duncan <pabs@pablotron.org>2016-03-09 01:18:37 -0500
commit5f3b78f7570e64e7337ebbf6a8d399366c4c75fd (patch)
tree01ae240dca725f23890316d9fe64aa1b0069b9f8
parent6e02499111871aa59042fc30e57b522f18be6e22 (diff)
downloadold-guff-5f3b78f7570e64e7337ebbf6a8d399366c4c75fd.tar.bz2
old-guff-5f3b78f7570e64e7337ebbf6a8d399366c4c75fd.zip
add comments
-rw-r--r--src/guff/handlers/blog.cr12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/guff/handlers/blog.cr b/src/guff/handlers/blog.cr
index 89393c3..21e7db7 100644
--- a/src/guff/handlers/blog.cr
+++ b/src/guff/handlers/blog.cr
@@ -161,6 +161,10 @@ class Guff::Handlers::BlogHandler < Guff::Handler
end
end
+ #######################
+ # post filter methods #
+ #######################
+
FILTERS = {
year: "year",
month: "month",
@@ -175,6 +179,10 @@ class Guff::Handlers::BlogHandler < Guff::Handler
end
end
+ ######################
+ # draw posts methods #
+ ######################
+
private def draw_posts(context, route, posts)
case route[:type]
when :list
@@ -202,6 +210,10 @@ class Guff::Handlers::BlogHandler < Guff::Handler
context.response.puts page
end
+ #####################
+ # draw tags methods #
+ #####################
+
TAG_TEMPLATES = TemplateCache.new({
body: "
<div class='post'>