mirror of
https://github.com/Bubka/2FAuth.git
synced 2025-06-12 07:56:50 +02:00
Fix 2FAccount preview calling a bad route
This commit is contained in:
parent
bf31a9b599
commit
0d2449adc7
@ -89,7 +89,7 @@
|
|||||||
|
|
||||||
getTOTP: function() {
|
getTOTP: function() {
|
||||||
|
|
||||||
this.axios.post('api/twofaccounts/otp', {data: this.id ? this.id : this.internal_uri }).then(response => {
|
this.axios.post('/api/twofaccounts/otp', {data: this.id ? this.id : this.internal_uri }).then(response => {
|
||||||
let spacePosition = Math.ceil(response.data.otp.length / 2);
|
let spacePosition = Math.ceil(response.data.otp.length / 2);
|
||||||
|
|
||||||
this.otp = response.data.otp.substr(0, spacePosition) + " " + response.data.otp.substr(spacePosition);
|
this.otp = response.data.otp.substr(0, spacePosition) + " " + response.data.otp.substr(spacePosition);
|
||||||
@ -130,7 +130,7 @@
|
|||||||
|
|
||||||
getHOTP: function() {
|
getHOTP: function() {
|
||||||
|
|
||||||
this.axios.post('api/twofaccounts/otp', {data: this.id ? this.id : this.internal_uri }).then(response => {
|
this.axios.post('/api/twofaccounts/otp', {data: this.id ? this.id : this.internal_uri }).then(response => {
|
||||||
let spacePosition = Math.ceil(response.data.otp.length / 2);
|
let spacePosition = Math.ceil(response.data.otp.length / 2);
|
||||||
|
|
||||||
this.otp = response.data.otp.substr(0, spacePosition) + " " + response.data.otp.substr(spacePosition)
|
this.otp = response.data.otp.substr(0, spacePosition) + " " + response.data.otp.substr(spacePosition)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user