Commit 7d2b37bc authored by Grzegorz Bizon's avatar Grzegorz Bizon

Fix resetting old token when fallback strategy is provided

parent 37add27a
......@@ -46,7 +46,7 @@ module TokenAuthenticatableStrategies
raise ArgumentError unless token.present?
instance[encrypted_field] = Gitlab::CryptoHelper.aes256_gcm_encrypt(token)
fallback_strategy.set_token(instance, nil) if fallback?
instance[token_field] = nil if fallback?
token
end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment