Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

.

  • Loading branch information...
commit c8187391e677c082b241faa8dd890f3b087ddd77 1 parent aca6432
@Seyun authored
Showing with 2 additions and 5 deletions.
  1. +2 −5 lib/Twitter.rb
View
7 lib/Twitter.rb
@@ -7,11 +7,8 @@ def self.tweet
users.each do |user|
menu = Menu.find(:first, :order => 'serve_at', :conditions => ['user_id = ? AND serve_at > ?', user.id, Time.now])
if menu != nil && (menu.serve_at.strftime("%d") == Time.now.strftime("%d"))
- access_token = prepare_access_token(user.consumer_key, user.consumer_secret,
- user.access_token, user.access_token_secret)
- result = access_token.request(:post,
- "http://api.twitter.com/1/statuses/update.json?status="+generate_tweet_contents(menu))
- return result
+ access_token = prepare_access_token(user.consumer_key, user.consumer_secret, user.access_token, user.access_token_secret)
+ access_token.request(:post, "http://api.twitter.com/1/statuses/update.json?status="+generate_tweet_contents(menu))
end
end
end
Please sign in to comment.
Something went wrong with that request. Please try again.