diff options
author | Chocobozzz <me@florianbigard.com> | 2022-10-07 14:23:42 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2022-10-07 14:28:35 +0200 |
commit | 2166c058f34dff6f91566930d12448805d829de7 (patch) | |
tree | 2b9100b8eccbac287d1105c765901f966a354986 /client/src/app/+admin/overview/users/user-edit/user-edit.ts | |
parent | d12b40fb96d56786a96c06a621f3d8e0a0d24f4a (diff) | |
download | PeerTube-2166c058f34dff6f91566930d12448805d829de7.tar.gz PeerTube-2166c058f34dff6f91566930d12448805d829de7.tar.zst PeerTube-2166c058f34dff6f91566930d12448805d829de7.zip |
Allow admins to disable two factor auth
Diffstat (limited to 'client/src/app/+admin/overview/users/user-edit/user-edit.ts')
-rw-r--r-- | client/src/app/+admin/overview/users/user-edit/user-edit.ts | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/client/src/app/+admin/overview/users/user-edit/user-edit.ts b/client/src/app/+admin/overview/users/user-edit/user-edit.ts index 6dae4110d..21e9629ab 100644 --- a/client/src/app/+admin/overview/users/user-edit/user-edit.ts +++ b/client/src/app/+admin/overview/users/user-edit/user-edit.ts | |||
@@ -60,10 +60,22 @@ export abstract class UserEdit extends FormReactive implements OnInit { | |||
60 | ] | 60 | ] |
61 | } | 61 | } |
62 | 62 | ||
63 | displayDangerZone () { | ||
64 | if (this.isCreation()) return false | ||
65 | if (this.user?.pluginAuth) return false | ||
66 | if (this.auth.getUser().id === this.user.id) return false | ||
67 | |||
68 | return true | ||
69 | } | ||
70 | |||
63 | resetPassword () { | 71 | resetPassword () { |
64 | return | 72 | return |
65 | } | 73 | } |
66 | 74 | ||
75 | disableTwoFactorAuth () { | ||
76 | return | ||
77 | } | ||
78 | |||
67 | getUserVideoQuota () { | 79 | getUserVideoQuota () { |
68 | return this.form.value['videoQuota'] | 80 | return this.form.value['videoQuota'] |
69 | } | 81 | } |