Skip to content

Commit

Permalink
appease rubocop
Browse files Browse the repository at this point in the history
  • Loading branch information
Andre LeBlanc committed Jun 7, 2019
1 parent f790920 commit 0b3be15
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/help_scout/api/access_token.rb
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,13 @@ def initialize(params)
@value = params[:access_token]
@expires_in = params[:expires_in]
return unless @expires_in

@expires_at = Time.now.utc + expires_in
end

def expired?
return false unless expires_at

Time.now.utc > expires_at
end

Expand Down

0 comments on commit 0b3be15

Please sign in to comment.