Permalink
Browse files

Remove unnecessary parentheses.

  • Loading branch information...
1 parent d5c0b2e commit 1831298f3e242ab16e7b44495e40dc321ff3d629 @kevintuhumury kevintuhumury committed Mar 19, 2012
View
2 lib/cameraplus/api/request.rb
@@ -23,7 +23,7 @@ def response
private
def request
- self.class.get(@url, query: @options)
+ self.class.get @url, query: @options
end
end
View
4 lib/cameraplus/page.rb
@@ -17,7 +17,7 @@ def parse
def parse_page
@url = @data.url
- @created_at = DateTime.parse(@data.timestamp)
+ @created_at = DateTime.parse @data.timestamp
@location = @data.location
@location_name = @data.locationname
@tweet_text = @data.tweettext
@@ -27,7 +27,7 @@ def parse_page
end
def parse_photos
- @photos ||= @data.images.map { |image| Photo.new(image) }
+ @photos ||= @data.images.map { |image| Photo.new image }
end
end
View
2 spec/cameraplus/api/request_spec.rb
@@ -20,7 +20,7 @@
use_vcr_cassette :request_api
- let(:response) { subject.call("/user/mostlylisa:pages") }
+ let(:response) { subject.call "/user/mostlylisa:pages" }
it "should have a response" do
response.should_not be_nil
View
6 spec/cameraplus/api/user_spec.rb
@@ -5,13 +5,13 @@
use_vcr_cassette :user
it "should be a hash" do
- response = Cameraplus::API::User.find("mostlylisa")
+ response = Cameraplus::API::User.find "mostlylisa"
response.should be_a Hash
end
it "should make a request to the Camera+ API" do
- Cameraplus::API::Request.should_receive(:call).with("/user/mostlylisa:pages", {})
- Cameraplus::API::User.find("mostlylisa")
+ Cameraplus::API::Request.should_receive(:call).with "/user/mostlylisa:pages", {}
+ Cameraplus::API::User.find "mostlylisa"
end
end
View
2 spec/cameraplus/page_spec.rb
@@ -27,7 +27,7 @@
}
end
- subject { Cameraplus::Page.new(data) }
+ subject { Cameraplus::Page.new data }
context "instance" do
View
2 spec/cameraplus/photo_spec.rb
@@ -13,7 +13,7 @@
}
end
- subject { Cameraplus::Photo.new(data) }
+ subject { Cameraplus::Photo.new data }
it "has a small version" do
subject.small.should eq "http://pics.campl.us/t/0/0b497f01791c851db1a17f81e0621a5c.jpg"

0 comments on commit 1831298

Please sign in to comment.