gjtorikian / jekyll-last-modified-at

A Jekyll plugin to show the last_modified_at time of a post.
MIT License
241 stars 38 forks source link

Plugin not working (possibly broke by commit 51396fed3f9634b2df5f042299a19d9fba5163f4) #73

Closed dleidert closed 4 years ago

dleidert commented 4 years ago

Hi there,

I packaged a lot of the Jekyll plugins for Debian GNU/Linux. I'm using Jekyll (3.8.3) myself and enabled the jekyll-last-modified-at plugin. But still page.last_modified_at stayed empty and {% last_modified_at %} was unrecognized. When I began to look into the issue I found that neither of the module classes gets loaded. In commit 51396fed3f9634b2df5f042299a19d9fba5163f4 the line Tag ; Hook was removed from jekyll-last-modified-at.rb. Was it intentional? Seems this is the culprit. Re-adding this line makes the plugin functional again.

gjtorikian commented 4 years ago

Hi there—I believe this was an errant change from bundle exec rubocop -a.

Could you let me know if adding these lines works for you:


    require 'jekyll-last-modified-at/tag'
    require 'jekyll-last-modified-at/hook'

If so, I'll push a new patch fix immediately.

dleidert commented 4 years ago

This works too.

dleidert commented 4 years ago

@gjtorikian : Thanks. Do you have any idea why your tests didn't reveal the issue? I'd suggest to add a test to catch this issue in the future.