Skip to content

Commit

Permalink
Merge pull request #121 from josh-m-sharpe/master
Browse files Browse the repository at this point in the history
expose json_result_object
  • Loading branch information
edwinwills authored Aug 23, 2019
2 parents 3b4786d + d362268 commit db2c0c6
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/google_places/spot.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ class Spot
attr_accessor :lat, :lng, :viewport, :name, :icon, :reference, :vicinity, :types, :id, :formatted_phone_number,
:international_phone_number, :formatted_address, :address_components, :street_number, :street, :city, :region,
:postal_code, :country, :rating, :url, :cid, :website, :reviews, :aspects, :zagat_selected, :zagat_reviewed,
:photos, :review_summary, :nextpagetoken, :price_level, :opening_hours, :events, :utc_offset, :place_id, :permanently_closed
:photos, :review_summary, :nextpagetoken, :price_level, :opening_hours, :events, :utc_offset, :place_id, :permanently_closed,
:json_result_object

# Search for Spots at the provided location
#
Expand Down Expand Up @@ -428,6 +429,7 @@ def self.multi_pages_request(method, multipage_request, options)
# @param [JSON] json_result_object a JSON object to create a Spot from
# @return [Spot] a newly created spot
def initialize(json_result_object, api_key)
@json_result_object = json_result_object
@reference = json_result_object['reference']
@place_id = json_result_object['place_id']
@vicinity = json_result_object['vicinity']
Expand Down

0 comments on commit db2c0c6

Please sign in to comment.