Sha256: 8bd57bf7fb387b6501867a76aef540a4c5302341155609c1f0c0a5dca768b0c6
Contents?: true
Size: 423 Bytes
Versions: 46
Compression:
Stored size: 423 Bytes
Contents
module ActiveModel class Error attr_reader :messages def initialize(msgs = {}) @messages = msgs || {} @messages.each { |attribute, messages| @messages[attribute] = messages.uniq } end def [](attribute) messages[attribute] end def delete(attribute) messages.delete(attribute) end def empty? messages.empty? end end end
Version data entries
46 entries across 46 versions & 2 rubygems