diff options
author | Rigel Kent <sendmemail@rigelk.eu> | 2019-11-25 11:16:12 +0100 |
---|---|---|
committer | Chocobozzz <chocobozzz@framasoft.org> | 2019-11-25 11:16:12 +0100 |
commit | ba7b7e572f0634e534320a057f4cc0a95f2a541d (patch) | |
tree | 687759585d7c92f865112ca3e920764471603b20 /server | |
parent | efcd6f2e625c1c5d06025f27a2bf3a84d3f8b483 (diff) | |
download | PeerTube-ba7b7e572f0634e534320a057f4cc0a95f2a541d.tar.gz PeerTube-ba7b7e572f0634e534320a057f4cc0a95f2a541d.tar.zst PeerTube-ba7b7e572f0634e534320a057f4cc0a95f2a541d.zip |
(plugins) adding signup scope and init hook, modifying ensureUserRegistrationAllowed allowedParams
Diffstat (limited to 'server')
-rw-r--r-- | server/middlewares/validators/users.ts | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/server/middlewares/validators/users.ts b/server/middlewares/validators/users.ts index 8615de406..c78c67a8c 100644 --- a/server/middlewares/validators/users.ts +++ b/server/middlewares/validators/users.ts | |||
@@ -283,7 +283,8 @@ const usersVideoRatingValidator = [ | |||
283 | const ensureUserRegistrationAllowed = [ | 283 | const ensureUserRegistrationAllowed = [ |
284 | async (req: express.Request, res: express.Response, next: express.NextFunction) => { | 284 | async (req: express.Request, res: express.Response, next: express.NextFunction) => { |
285 | const allowedParams = { | 285 | const allowedParams = { |
286 | body: req.body | 286 | body: req.body, |
287 | ip: req.ip | ||
287 | } | 288 | } |
288 | 289 | ||
289 | const allowedResult = await Hooks.wrapPromiseFun( | 290 | const allowedResult = await Hooks.wrapPromiseFun( |