mirror of
https://github.com/yu-i-i/overleaf-cep.git
synced 2026-06-03 06:09:02 +02:00
fix cancel subscription on delete user
This commit is contained in:
@@ -21,7 +21,7 @@ module.exports =
|
||||
(cb)->
|
||||
ProjectDeleter.deleteUsersProjects user._id, cb
|
||||
(cb)->
|
||||
SubscriptionHandler.cancelSubscription user._id, cb
|
||||
SubscriptionHandler.cancelSubscription user, cb
|
||||
(cb)->
|
||||
user.remove cb
|
||||
], (err)->
|
||||
|
||||
@@ -49,5 +49,5 @@ describe "UserDeleter", ->
|
||||
|
||||
it "should unsubscribe the user", (done)->
|
||||
@UserDeleter.deleteUser @user._id, (err)=>
|
||||
@SubscriptionHandler.cancelSubscription.calledWith(@user._id).should.equal true
|
||||
@SubscriptionHandler.cancelSubscription.calledWith(@user).should.equal true
|
||||
done()
|
||||
|
||||
Reference in New Issue
Block a user