mirror of
https://github.com/docusealco/docuseal
synced 2026-11-13 23:52:32 -05:00
update routes
This commit is contained in:
1 parent
63a874528a
commit
25504e8cb1
5 files changed
+18
-19
No files matched your search
@@ -285,7 +285,7 @@ export default {
|
||||
}, 1000)
|
||||
},
|
||||
sendVerificationCode () {
|
||||
return fetch(this.baseUrl + '/api/send_phone_verification_code', {
|
||||
const options = {
|
||||
method: 'POST',
|
||||
body: JSON.stringify({
|
||||
submitter_slug: this.submitterSlug,
|
||||
@@ -293,6 +293,14 @@ export default {
|
||||
phone: this.fullInternationalPhoneValue
|
||||
}),
|
||||
headers: { 'Content-Type': 'application/json' }
|
||||
}
|
||||
|
||||
return fetch(this.baseUrl + `/s/${this.submitterSlug}/send_phone_verification_code`, options).then((resp) => {
|
||||
if (resp.status === 404) {
|
||||
return fetch(this.baseUrl + '/api/send_phone_verification_code', options)
|
||||
} else {
|
||||
return resp
|
||||
}
|
||||
}).then(async (resp) => {
|
||||
if ([422, 429].includes(resp.status)) {
|
||||
const data = await resp.json()
|
||||
|
||||
Reference in new issue
Block a user