google-place-text-search 0.0.1 → 0.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a8a830ca5e133e2ca56884c1544a0b5440a74261
4
- data.tar.gz: cda4174613f447026c118a7806c6543dba31dc6d
3
+ metadata.gz: c4c5b6b65cb33006518292691b985941a762c0fc
4
+ data.tar.gz: cc81164ee9e4f78a5923bec9d98cb3cd668691fd
5
5
  SHA512:
6
- metadata.gz: 595a13702406dad283e6ae975f15919c614b2b86116175d960c17b7f5fa9a66af816eb5794fc42243496f03f5e8326e94c5e1e3ccf454729e5c15e663ba8990d
7
- data.tar.gz: 9cdf7dd8e3a9637f55ee6afba872cddd22c8cd3c3809807f9e38e4801398c5ffb2672e5bc782072da4ebdf2efce2f8fcda35107ea26a3b10247f0594d96b36ad
6
+ metadata.gz: 8b7816762eeab71f75e305ee84f088cf762c6164850546c2af6461674728bba8e0cf095dbf4229f64f568661b2508019bcd8de20a839613dbb917bd269943654
7
+ data.tar.gz: a8d5c50dc296211f83ad41add354b5a71c6fa2f3c3aa790ac278d5ef75d451eea6aba39b22ceb5c131efada27219492765de9347243dcbe3f3afe49286b63121
@@ -1,14 +1,16 @@
1
1
  class GooglePlaceTextSearch
2
-
2
+ require 'debugger'
3
3
  require 'httparty'
4
4
  require 'json'
5
5
 
6
6
  def get_response(api_key,radius,location,query)
7
7
  url = "https://maps.googleapis.com/maps/api/place/textsearch/json"
8
8
  #location="#{lat},#{lng}"
9
- response = HTTParty.get("#{url}", :query=>{:api_key=>api_key,:query=>query, :location=>location,:radius=>radius})
9
+
10
+ query_data = {:key=>api_key,:query=>query, :location=>location,:radius=>radius}
11
+ response = HTTParty.get("#{url}", :query=>query_data)
10
12
 
11
- json = JSON.parse(response.body)
13
+ json = JSON.parse(response.body)
12
14
  return json
13
15
  end
14
16
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-place-text-search
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Abhishek Sharma