Releases: pote/hashifiable
Releases · pote/hashifiable
Accepting Strings as hash keys
Thanks to @zspackett triggering the need for this feature hashifiable now supports using Strings as keys for the hash representation of your objects!
class TestUser < Struct.new(:id, :name, :credit_card, :secret_token, :quote)
extend Hashifiable
hashify :id,
:name,
'quote',
'random' => Proc.new { [1, 2, 3].sample },
end