diff --git a/core/server/models/base/listeners.js b/core/server/models/base/listeners.js index d9c1263940..05dbad8363 100644 --- a/core/server/models/base/listeners.js +++ b/core/server/models/base/listeners.js @@ -31,9 +31,9 @@ common.events.on('user.deactivated', function (userModel, options) { return; } - models.Accesstoken.destroyByUser(options) + models.Accesstoken.destroyByUser(_.omit(options, 'transacting')) .then(function () { - return models.Refreshtoken.destroyByUser(options); + return models.Refreshtoken.destroyByUser(_.omit(options, 'transacting')); }) .catch(function (err) { common.logging.error(new common.errors.GhostError({