giant_bomb 0.2.0 → 0.3.0
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/giant_bomb.gemspec +1 -1
- data/lib/giant_bomb/attributes.rb +4 -0
- data/lib/giant_bomb/search.rb +9 -2
- metadata +1 -1
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.
|
1
|
+
0.3.0
|
data/giant_bomb.gemspec
CHANGED
data/lib/giant_bomb/search.rb
CHANGED
@@ -2,8 +2,8 @@ module GiantBomb
|
|
2
2
|
class Search
|
3
3
|
include HTTParty
|
4
4
|
format :json
|
5
|
-
|
6
|
-
|
5
|
+
include HTTParty::Icebox
|
6
|
+
cache :store => 'file', :timeout => 120, :location => Dir.tmpdir
|
7
7
|
|
8
8
|
base_uri 'api.giantbomb.com'
|
9
9
|
|
@@ -32,5 +32,12 @@ module GiantBomb
|
|
32
32
|
Game.new(response["results"], self)
|
33
33
|
end
|
34
34
|
|
35
|
+
def get_game(game_id)
|
36
|
+
response = self.class.get("/game/#{game_id}/", :query => default_query_options)
|
37
|
+
game = Game.new(response["results"], self)
|
38
|
+
game.loaded = true
|
39
|
+
game
|
40
|
+
end
|
41
|
+
|
35
42
|
end
|
36
43
|
end
|