Skip to content

Commit

Permalink
don't expose data in ObjectifiedHash
Browse files Browse the repository at this point in the history
  • Loading branch information
NARKOZ committed Jan 15, 2013
1 parent ee59c2e commit f2ba111
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions lib/gitlab/objectified_hash.rb
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
module Gitlab
# Converts hashes to the objects.
class ObjectifiedHash
attr_reader :data

# Creates a new ObjectifiedHash.
def initialize(hash)
@data = hash.inject({}) do |data, (key,value)|
Expand All @@ -14,7 +12,7 @@ def initialize(hash)

# Patches Object#id in Ruby 1.8
def id
self.data['id']
@data['id']
end

# Delegate to ObjectifiedHash
Expand Down

0 comments on commit f2ba111

Please sign in to comment.