Flowdock
default(*args) public

Same as Hash#default where the key passed as argument can be either a string or a symbol:

hash = ActiveSupport::HashWithIndifferentAccess.new(1)
hash.default                   # => 1

hash = ActiveSupport::HashWithIndifferentAccess.new { |hash, key| key }
hash.default                   # => nil
hash.default('foo')            # => 'foo'
hash.default(:foo)             # => 'foo'
Show source
Register or log in to add new notes.