SyntaxFix
Write A Post
Hire A Developer
Questions
I use this:
@var.respond_to?(:keys)
It works for Hash and ActiveSupport::HashWithIndifferentAccess.