regNameSurnameMandatory
askUSernameTelegramToTheReg @ davanti all'username
This commit is contained in:
@@ -1,9 +1,10 @@
|
||||
import { Patterns } from '@/common'
|
||||
import { tools } from '../store/Modules/tools'
|
||||
|
||||
export function complexity(password: string) {
|
||||
return Patterns.Password.test(password)
|
||||
}
|
||||
|
||||
export function complexityUser(username: string) {
|
||||
return Patterns.Username.test(username)
|
||||
return Patterns.Username.test(tools.rimuoviAtInizio(username))
|
||||
}
|
||||
|
||||
@@ -2,6 +2,8 @@ import { default as Axios, AxiosResponse } from 'axios'
|
||||
// import { IPayload } from 'model'
|
||||
import { GlobalConfig, PayloadMessageTypes } from '../common'
|
||||
|
||||
import { tools } from '@store/Modules/tools'
|
||||
|
||||
import { helpers } from '@vuelidate/validators'
|
||||
const { withAsync } = helpers
|
||||
|
||||
@@ -16,7 +18,7 @@ export function _registereduser (userName: string) {
|
||||
return res.status !== PayloadMessageTypes.statusfound
|
||||
}
|
||||
|
||||
return Axios.get(VALIDATE_USER_URL + process.env.APP_ID + '/' + userName)
|
||||
return Axios.get(VALIDATE_USER_URL + process.env.APP_ID + '/' + tools.rimuoviAtInizio(userName))
|
||||
.then(onSuccess)
|
||||
.catch((err) => {
|
||||
return true
|
||||
|
||||
Reference in New Issue
Block a user