Class: Boletoman::Services::Itau::Token::Cache

Inherits:
Object
  • Object
show all
Defined in:
lib/boletoman/services/itau/token/cache.rb

Constant Summary collapse

KEY =
'boletoman-itau-token'.freeze

Instance Method Summary collapse

Instance Method Details

#fetchObject



10
11
12
13
14
15
16
# File 'lib/boletoman/services/itau/token/cache.rb', line 10

def fetch
  if redis
    get || set
  else
    request.token
  end
end