Browse files

Fixing passing the mapped fields via Mapper#mapping

  • Loading branch information...
1 parent 309e3a1 commit 9b6a4d4d234b578052021e9e2eba11769fefd565 @andrewtimberlake andrewtimberlake committed Mar 9, 2012
Showing with 2 additions and 1 deletion.
  1. +1 −1 lib/map_fields/mapper.rb
  2. +1 −0 lib/map_fields/mapping.rb
View
2 lib/map_fields/mapper.rb
@@ -30,7 +30,7 @@ def error!
end
def mapping
- @mapping['mapping']
+ @mapping.mapping
end
def mapped?
View
1 lib/map_fields/mapping.rb
@@ -14,6 +14,7 @@ def initialize(mapping, fields)
hash[field_to_symbol(@fields[key])] = value
}
end
+ attr_reading :mapping
def [](index)
@mapping[index]

0 comments on commit 9b6a4d4

Please sign in to comment.