aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/helpers/custom-validators
diff options
context:
space:
mode:
authorKimsible <kimsible@users.noreply.github.com>2021-04-28 17:33:55 +0200
committerKimsible <kimsible@users.noreply.github.com>2021-05-05 11:47:03 +0200
commit1e37d32f4bdc51045cd85d01ea1035fd53e0d32c (patch)
tree2e7bcf053989fc5be9e3ef29558cf1fcf32f8453 /server/helpers/custom-validators
parentff8c5ccf09cfe6a469777d4789625f8fdb004408 (diff)
downloadPeerTube-1e37d32f4bdc51045cd85d01ea1035fd53e0d32c.tar.gz
PeerTube-1e37d32f4bdc51045cd85d01ea1035fd53e0d32c.tar.zst
PeerTube-1e37d32f4bdc51045cd85d01ea1035fd53e0d32c.zip
Add server API actors route
Diffstat (limited to 'server/helpers/custom-validators')
-rw-r--r--server/helpers/custom-validators/actor.ts10
1 files changed, 10 insertions, 0 deletions
diff --git a/server/helpers/custom-validators/actor.ts b/server/helpers/custom-validators/actor.ts
new file mode 100644
index 000000000..ad129e080
--- /dev/null
+++ b/server/helpers/custom-validators/actor.ts
@@ -0,0 +1,10 @@
1import { isAccountNameValid } from './accounts'
2import { isVideoChannelNameValid } from './video-channels'
3
4function isActorNameValid (value: string) {
5 return isAccountNameValid(value) || isVideoChannelNameValid(value)
6}
7
8export {
9 isActorNameValid
10}