class GH::LinkFollower

Public Instance Methods

modify_hash(hash) click to toggle source
Calls superclass method
# File lib/gh/link_follower.rb, line 6
def modify_hash(hash)
  hash = super
  setup_lazy_loading(hash) if hash['_links']
  hash
rescue Exception => error
  raise Error.new(error, hash)
end

Private Instance Methods

lazy_load(hash, key) click to toggle source
# File lib/gh/link_follower.rb, line 16
def lazy_load(hash, key)
  link = hash['_links'][key]
  { key => self[link['href']] } if link
rescue Exception => error
  raise Error.new(error, hash)
end