mirror of
https://github.com/yu-i-i/overleaf-cep.git
synced 2026-05-27 11:01:56 +02:00
Propagate the error further up the stack
Useful for error reporting and metrics.
This commit is contained in:
@@ -33,7 +33,7 @@ module.exports =
|
||||
licenceName: licence.name
|
||||
has_personal_subscription: subscription?
|
||||
|
||||
createInvite: (req, res)->
|
||||
createInvite: (req, res, next)->
|
||||
user = AuthenticationController.getSessionUser(req)
|
||||
licence = SubscriptionDomainHandler.getLicenceUserCanJoin(user)
|
||||
|
||||
@@ -42,6 +42,6 @@ module.exports =
|
||||
|
||||
TeamInvitesHandler.createDomainInvite user, licence, (err) ->
|
||||
if err?
|
||||
res.sendStatus 500
|
||||
next(err)
|
||||
else
|
||||
res.sendStatus 200
|
||||
|
||||
Reference in New Issue
Block a user