Fail gracefully and log error when token missing in Redis
This commit is contained in:
parent
1995e6dda2
commit
de67f59d5c
@ -31,6 +31,9 @@ class RemoteStorageAuthorization < ApplicationRecord
|
||||
def delete_token_from_redis
|
||||
key = "authorizations:#{user.cn}:#{token}"
|
||||
redis.srem? key, redis.smembers(key)
|
||||
rescue => e
|
||||
Rails.logger.error e
|
||||
Sentry.capture_exception(e) if Setting.sentry_enabled?
|
||||
end
|
||||
|
||||
private
|
||||
|
Loading…
x
Reference in New Issue
Block a user