Permalink
Browse files

added perform_get_request

  • Loading branch information...
1 parent 98adeec commit 27e061c0a48a4e24af43f24c2515836ea1fbb829 @pilu committed May 14, 2011
Showing with 9 additions and 7 deletions.
  1. +1 −1 VERSION
  2. +5 −1 lib/musix_match/api/base.rb
  3. +3 −5 musix_match.gemspec
View
@@ -1 +1 @@
-0.1.13
+0.1.14
@@ -25,7 +25,7 @@ def self.url_for(method, params={})
def self.get(method, params={})
raise APIKeyNotSpecifiedException.new('You must specify the API key. MusixMatch::API::Base.api_key = "YOUR_API_KEY"') if api_key.nil?
- response = HTTParty.get(url_for(method, params))
+ response = perform_get_request(url_for(method, params))
parsed_response = case response.parsed_response
when Hash
response.parsed_response
@@ -38,6 +38,10 @@ def self.get(method, params={})
end
parsed_response
end
+
+ def self.perform_get_request(url)
+ HTTParty.get(url)
+ end
def api_key
self.class.api_key
View
@@ -5,11 +5,11 @@
Gem::Specification.new do |s|
s.name = %q{musix_match}
- s.version = "0.1.12"
+ s.version = "0.1.14"
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
s.authors = ["Andrea Franz"]
- s.date = %q{2011-01-08}
+ s.date = %q{2011-05-14}
s.description = %q{API wrapper for musixmatch.com API's}
s.email = %q{andrea@gravityblast.com}
s.extra_rdoc_files = [
@@ -32,7 +32,6 @@ Gem::Specification.new do |s|
"lib/musix_match/lyrics_search_result.rb",
"lib/musix_match/models/lyrics.rb",
"lib/musix_match/models/model.rb",
- "lib/musix_match/models/subtitle.rb",
"lib/musix_match/models/track.rb",
"lib/musix_match/track_find_result.rb",
"lib/musix_match/track_search_result.rb",
@@ -54,7 +53,7 @@ Gem::Specification.new do |s|
s.homepage = %q{http://github.com/pilu/musix_match}
s.rdoc_options = ["--main=README.rdoc", "--charset=UTF-8"]
s.require_paths = ["lib"]
- s.rubygems_version = %q{1.3.7}
+ s.rubygems_version = %q{1.5.0}
s.summary = %q{API wrapper for musixmatch.com API's}
s.test_files = [
"spec/api/base_spec.rb",
@@ -74,7 +73,6 @@ Gem::Specification.new do |s|
]
if s.respond_to? :specification_version then
- current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
s.specification_version = 3
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then

0 comments on commit 27e061c

Please sign in to comment.