Class: GH::Normalizer
Overview
Public: A Wrapper class that deals with normalizing Github responses.
Instance Attribute Summary
Attributes inherited from Wrapper
Instance Method Summary collapse
Methods inherited from Wrapper
#[], [], double_dispatch, #initialize, #inspect, #load, #prefixed, #reset, wraps
Constructor Details
This class inherits a constructor from GH::Wrapper
Instance Method Details
#generate_response(key, response) ⇒ Object
9 10 11 12 13 |
# File 'lib/gh/normalizer.rb', line 9 def generate_response(key, response) result = super links(result)['self'] ||= { 'href' => frontend.full_url(key).to_s } if result.respond_to? :to_hash result end |