mirror of
https://github.com/TeamPiped/Piped.git
synced 2025-08-09 20:24:09 +00:00
register page: add password confirm field
This commit is contained in:
@@ -25,6 +25,17 @@
|
||||
@keyup.enter="register"
|
||||
/>
|
||||
</div>
|
||||
<div>
|
||||
<input
|
||||
v-model="passwordConfirm"
|
||||
class="input"
|
||||
type="password"
|
||||
autocomplete="password"
|
||||
:placeholder="$t('login.password_confirm')"
|
||||
:aria-label="$t('login.password_confirm')"
|
||||
@keyup.enter="register"
|
||||
/>
|
||||
</div>
|
||||
<div>
|
||||
<a v-t="'titles.register'" class="btn w-auto" @click="register" />
|
||||
</div>
|
||||
@@ -68,6 +79,10 @@ export default {
|
||||
methods: {
|
||||
register() {
|
||||
if (!this.username || !this.password) return;
|
||||
if (this.password != this.passwordConfirm) {
|
||||
alert(this.$t("login.passwords_incorrect"));
|
||||
return;
|
||||
}
|
||||
if (isEmail(this.username) && !this.forceUnsecureRegister) {
|
||||
this.showUnsecureRegisterDialog = true;
|
||||
return;
|
||||
|
Reference in New Issue
Block a user