carlosparamio-geoplanet 0.2.0 → 0.2.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.
- data/README.rdoc +10 -1
- data/geoplanet.gemspec +3 -3
- data/lib/geoplanet.rb +13 -2
- data/lib/geoplanet/version.rb +1 -1
- metadata +2 -2
data/README.rdoc
CHANGED
@@ -93,6 +93,11 @@ Additionally, geoplanet has the following gem dependencies:
|
|
93
93
|
* rest-client >= 0.9
|
94
94
|
* json >= 1.1.3
|
95
95
|
|
96
|
+
Please note that if you have ActiveSupport::JSON defined (either by
|
97
|
+
manually having loaded it or when you use geoplanet within a Rails
|
98
|
+
application) the json dependency will be ignored and geoplanet uses
|
99
|
+
ActiveSupport::JSON instead.
|
100
|
+
|
96
101
|
== INSTALL:
|
97
102
|
|
98
103
|
* gem install carlosparamio-geoplanet --source http://gems.github.com
|
@@ -120,4 +125,8 @@ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
|
120
125
|
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
121
126
|
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
122
127
|
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
123
|
-
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
128
|
+
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
129
|
+
|
130
|
+
== CONTRIBUTORS:
|
131
|
+
|
132
|
+
Nielsomat <http://github.com/Nielsomat> : Usage of ActiveSupport::JSON when available
|
data/geoplanet.gemspec
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
Gem::Specification.new do |s|
|
2
2
|
s.name = "geoplanet"
|
3
|
-
s.version = "0.2.
|
4
|
-
s.date = "2009-
|
3
|
+
s.version = "0.2.2"
|
4
|
+
s.date = "2009-04-01"
|
5
5
|
s.summary = "A Ruby wrapper for the Yahoo! GeoPlanet API."
|
6
6
|
s.email = "carlosparamio@gmail.com"
|
7
7
|
s.homepage = "http://github.com/carlosparamio/geoplanet/"
|
@@ -24,4 +24,4 @@ Gem::Specification.new do |s|
|
|
24
24
|
|
25
25
|
s.has_rdoc = false
|
26
26
|
s.rdoc_options = ["--main", "README.rdoc"]
|
27
|
-
end
|
27
|
+
end
|
data/lib/geoplanet.rb
CHANGED
@@ -1,4 +1,15 @@
|
|
1
|
-
%w{rubygems rest_client
|
1
|
+
%w{rubygems rest_client}.each { |x| require x }
|
2
|
+
|
3
|
+
if defined?(ActiveSupport::JSON)
|
4
|
+
JSON = ActiveSupport::JSON
|
5
|
+
module JSON
|
6
|
+
def self.parse(json)
|
7
|
+
decode(json)
|
8
|
+
end
|
9
|
+
end
|
10
|
+
else
|
11
|
+
require 'json'
|
12
|
+
end
|
2
13
|
|
3
14
|
require 'geoplanet/version'
|
4
15
|
require 'geoplanet/base'
|
@@ -15,4 +26,4 @@ module GeoPlanet
|
|
15
26
|
class BadRequest < StandardError; end
|
16
27
|
class NotFound < StandardError; end
|
17
28
|
class NotAcceptable < StandardError; end
|
18
|
-
end
|
29
|
+
end
|
data/lib/geoplanet/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: carlosparamio-geoplanet
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Carlos Paramio
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2009-
|
12
|
+
date: 2009-04-01 00:00:00 -07:00
|
13
13
|
default_executable:
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|