diff options
author | Josh Morel <morel.josh@hotmail.com> | 2018-11-21 02:48:29 -0500 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2018-11-21 08:48:29 +0100 |
commit | fc2ec87a8c4dcfbb91a1a62cf4c07a2a8e6a50fe (patch) | |
tree | a2cea5e299c5f1a731da99277949ea2f0bb35659 /server/controllers/api/users/index.ts | |
parent | 04b8c3fba614efc3827f583096c78b08cb668470 (diff) | |
download | PeerTube-fc2ec87a8c4dcfbb91a1a62cf4c07a2a8e6a50fe.tar.gz PeerTube-fc2ec87a8c4dcfbb91a1a62cf4c07a2a8e6a50fe.tar.zst PeerTube-fc2ec87a8c4dcfbb91a1a62cf4c07a2a8e6a50fe.zip |
enable email verification by admin (#1348)
* enable email verification by admin
* rename/label to set email as verified
to be more explicit that admin is not sending
another email to confirm
* add update user emailVerified check-params test
* make user.model emailVerified property required
Diffstat (limited to 'server/controllers/api/users/index.ts')
-rw-r--r-- | server/controllers/api/users/index.ts | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/server/controllers/api/users/index.ts b/server/controllers/api/users/index.ts index 9fcb8077f..87fab4a40 100644 --- a/server/controllers/api/users/index.ts +++ b/server/controllers/api/users/index.ts | |||
@@ -262,6 +262,7 @@ async function updateUser (req: express.Request, res: express.Response, next: ex | |||
262 | const roleChanged = body.role !== undefined && body.role !== userToUpdate.role | 262 | const roleChanged = body.role !== undefined && body.role !== userToUpdate.role |
263 | 263 | ||
264 | if (body.email !== undefined) userToUpdate.email = body.email | 264 | if (body.email !== undefined) userToUpdate.email = body.email |
265 | if (body.emailVerified !== undefined) userToUpdate.emailVerified = body.emailVerified | ||
265 | if (body.videoQuota !== undefined) userToUpdate.videoQuota = body.videoQuota | 266 | if (body.videoQuota !== undefined) userToUpdate.videoQuota = body.videoQuota |
266 | if (body.videoQuotaDaily !== undefined) userToUpdate.videoQuotaDaily = body.videoQuotaDaily | 267 | if (body.videoQuotaDaily !== undefined) userToUpdate.videoQuotaDaily = body.videoQuotaDaily |
267 | if (body.role !== undefined) userToUpdate.role = body.role | 268 | if (body.role !== undefined) userToUpdate.role = body.role |