Skip to content

Commit

Permalink
TTL 1 week for tipper client search_user
Browse files Browse the repository at this point in the history
  • Loading branch information
Scott Li committed Dec 23, 2013
1 parent 467241f commit e803bad
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/services/tipper_client.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ module TipperClient
extend self

def search_user(screen_name)
# Cache TTL should be 1 day to 1 week
Rails.cache.fetch(screen_name) do
# Cache TTL should be 1 week
Rails.cache.fetch(screen_name, expires_in: 1.week) do
user = TWITTER_CLIENT.user(screen_name)

{
Expand Down

0 comments on commit e803bad

Please sign in to comment.