Fix refresh to lazily load connection

This commit is contained in:
Stan Hu 2016-11-11 16:10:12 -08:00
parent b25ebfe67b
commit 3b9d1c0f5d

View file

@ -45,8 +45,7 @@ module Bitbucket
@expires_at = response.expires_at
@expires_in = response.expires_in
@refresh_token = response.refresh_token
@connection = OAuth2::AccessToken.new(@client, @token, refresh_token: @refresh_token, expires_at: @expires_at, expires_in: @expires_in)
@connection = nil
end
private