]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - server/helpers/custom-validators/misc.ts
Update webpack stack
[github/Chocobozzz/PeerTube.git] / server / helpers / custom-validators / misc.ts
index 83f50a7fef69e92325d07d5c6fb0e8a29ccaa50f..b1291ba7a5b38a8f91a9e5a6f1d14c068d1731ee 100644 (file)
@@ -1,8 +1,8 @@
-function exists (value) {
+function exists (value: any) {
   return value !== undefined && value !== null
 }
 
-function isArray (value) {
+function isArray (value: any) {
   return Array.isArray(value)
 }
 
@@ -12,3 +12,12 @@ export {
   exists,
   isArray
 }
+
+declare global {
+  namespace ExpressValidator {
+    export interface Validator {
+      exists,
+      isArray
+    }
+  }
+}