From 1ec31345974b9b93585ce55280f53dcf492cd828 Mon Sep 17 00:00:00 2001 From: Kevin Huang <44907675+Ynng@users.noreply.github.com> Date: Fri, 16 Oct 2020 15:42:12 -0400 Subject: [PATCH] replaced replaceAll() with replace() + regex --- src/views/loginAccount.vue | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/views/loginAccount.vue b/src/views/loginAccount.vue index 7a652cf..c335d67 100644 --- a/src/views/loginAccount.vue +++ b/src/views/loginAccount.vue @@ -137,8 +137,8 @@ export default { return; } loginWithPhone({ - countrycode: this.countryCode.replace("+", "").replaceAll(" ", ""), - phone: this.phoneNumber.replaceAll(" ", ""), + countrycode: this.countryCode.replace("+", "").replace(/\s/g, ''), + phone: this.phoneNumber.replace(/\s/g, ''), password: "fakePassword", md5_password: md5(this.password).toString(), }) @@ -156,7 +156,7 @@ export default { return; } loginWithEmail({ - email: this.email.replaceAll(" ", ""), + email: this.email.replace(/\s/g, ''), password: "fakePassword", md5_password: md5(this.password).toString(), })