I get this error when I try to use time_ago_in_words
:
Comparison of String with ActiveSupport::Duration failed
I'm trying to check whether an object was created more than 8 minutes ago:
<% if time_ago_in_words(obj.created_at) > 8.minutes %>
<p>Yes</p>
<% end %>
Would appreciate it if anyone knows the correct way to perform this test.