Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class Response
- attr_reader :errors
- attr_accessor :data
- def initialize data=[]
- @data = []
- @data << data
- @data.flatten!
- @errors = ActiveModel::Errors.new(self)
- end
- def self.human_attribute_name field, mappings
- mappings[:default]
- end
- end
Add Comment
Please, Sign In to add comment