diff options
author | re4k <re4k@re4k.info> | 2013-05-05 16:49:36 +0900 |
---|---|---|
committer | re4k <re4k@re4k.info> | 2013-05-05 16:49:36 +0900 |
commit | 33fa30d3a5e116cfc6b1347605a57aed49469900 (patch) | |
tree | dfacfac2f48c0aa9f89024075f54c0ac37e74817 /lib/aclog | |
parent | 0544f801143a937a6a7880299319a7eb61b28523 (diff) | |
download | aclog-33fa30d3a5e116cfc6b1347605a57aed49469900.tar.gz |
update settings (rails: web/receiver)
Diffstat (limited to 'lib/aclog')
-rw-r--r-- | lib/aclog/notification.rb | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/aclog/notification.rb b/lib/aclog/notification.rb index 85919a3..0404f4c 100644 --- a/lib/aclog/notification.rb +++ b/lib/aclog/notification.rb @@ -9,10 +9,11 @@ module Aclog def self.reply_tweet(user, text, tweet) @@account ||= Twitter::Client.new(consumer_key: Settings.notification.consumer.key, consumer_secret: Settings.notification.consumer.secret, - oauth_token: Settings.notification.token.token, - oauth_token_secret: Settings.notification.token.secret) + oauth_token: Settings.notification.token[0].token, + oauth_token_secret: Settings.notification.token[0].secret) + + url = Rails.application.routes.url_helpers.tweet_url(host: Settings.base_url, id: tweet.id) - url = Settings.tweet_url.gsub(/:id/, tweet.id.to_s) begin @@account.update("@#{user.screen_name} #{text} #{url}", :in_reply_to_status_id => tweet.id) rescue Exception |