diff options
author | Loek Le Blansch <loek@pipeframe.xyz> | 2025-03-17 21:17:35 +0100 |
---|---|---|
committer | Loek Le Blansch <loek@pipeframe.xyz> | 2025-03-17 21:17:35 +0100 |
commit | ddb547694fbc649933328effd1ae08dab5eb1eea (patch) | |
tree | 26daaf1a1407f84d4cf86d225070bd2d4a0c3f97 | |
parent | cdceb8d1c00fc6aab6566e7dfb8b5ee536cc989b (diff) |
fix rendering for new post
-rw-r--r-- | _plugins/filters.rb | 3 | ||||
-rw-r--r-- | _plugins/meta.rb | 1 |
2 files changed, 3 insertions, 1 deletions
diff --git a/_plugins/filters.rb b/_plugins/filters.rb index 78eb04f..ffbd61c 100644 --- a/_plugins/filters.rb +++ b/_plugins/filters.rb @@ -1,6 +1,7 @@ module Filters def datefmt(input) - return input.strftime("%F") + return input.strftime("%F") if input.is_a? Time + return "???" end def sentence_join(items, fallback = "") diff --git a/_plugins/meta.rb b/_plugins/meta.rb index 0e25871..2bf6662 100644 --- a/_plugins/meta.rb +++ b/_plugins/meta.rb @@ -35,6 +35,7 @@ class Meta < Jekyll::Generator def transform_data(site, slug) data = site.data['post'][slug] + if data['git_log'] == nil then data['git_log'] = [ { } ] end data['git_log'] = data['git_log'].sort { |c| c['date'].to_i } git_log = data['git_log'].filter do |commit| |