1
0
Fork 0
peertube/server/helpers/custom-validators/accounts.ts

23 lines
514 B
TypeScript
Raw Normal View History

import { isUserDescriptionValid, isUserUsernameValid } from './users'
import { exists } from './misc'
2017-11-10 08:48:08 -05:00
2017-11-14 11:31:26 -05:00
function isAccountNameValid (value: string) {
2017-11-10 08:48:08 -05:00
return isUserUsernameValid(value)
}
function isAccountIdValid (value: string) {
return exists(value)
}
function isAccountDescriptionValid (value: string) {
return isUserDescriptionValid(value)
}
2017-11-10 08:48:08 -05:00
// ---------------------------------------------------------------------------
export {
isAccountIdValid,
isAccountDescriptionValid,
2017-11-14 11:31:26 -05:00
isAccountNameValid
2017-11-10 08:48:08 -05:00
}