Permalink
Browse files

Add aliases for search methods

  • Loading branch information...
1 parent 0fc68f1 commit 05dd3e5a058ef69f874cfe33ae35b01f574e549b @sferik committed Sep 24, 2010
Showing with 6 additions and 3 deletions.
  1. +6 −3 lib/twitter/search.rb
View
@@ -95,6 +95,7 @@ def per_page(num)
@query[:rpp] = num
self
end
+ alias :rpp :per_page
# Which page of results to fetch
def page(num)
@@ -104,10 +105,11 @@ def page(num)
# Only searches tweets since a given id.
# Recommended to use this when possible.
- def since(since_id)
- @query[:since_id] = since_id
+ def since_id(id)
+ @query[:since_id] = id
self
end
+ alias :since :since_id
# From the advanced search form, not documented in the API
# Format YYYY-MM-DD
@@ -129,10 +131,11 @@ def geocode(lat, long, range)
self
end
- def max(id)
+ def max_id(id)
@query[:max_id] = id
self
end
+ alias :max :max_id
# Clears all the query filters to make a new search
def clear

0 comments on commit 05dd3e5

Please sign in to comment.