1
0
Fork 0
peertube/server/helpers/custom-validators/accounts.ts
2019-07-25 16:23:44 +02:00

22 lines
514 B
TypeScript

import { isUserDescriptionValid, isUserUsernameValid } from './users'
import { exists } from './misc'
function isAccountNameValid (value: string) {
return isUserUsernameValid(value)
}
function isAccountIdValid (value: string) {
return exists(value)
}
function isAccountDescriptionValid (value: string) {
return isUserDescriptionValid(value)
}
// ---------------------------------------------------------------------------
export {
isAccountIdValid,
isAccountDescriptionValid,
isAccountNameValid
}