]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - shared/models/plugins/server-hook.model.ts
Use search client scope
[github/Chocobozzz/PeerTube.git] / shared / models / plugins / server-hook.model.ts
index 30469856cd7ff971016009d406e0e7155c3ed68f..6729e2dabab4f581be6bb4b90366835e8ef634a9 100644 (file)
@@ -7,12 +7,12 @@ export type ServerFilterHookName =
   'filter:api.video-thread.create.accept.result' |
   'filter:api.video-comment-reply.create.accept.result' |
 
-  'filter:api.video-thread-comments.list.params' |
-  'filter:api.video-thread-comments.list.result' |
-
   'filter:api.video-threads.list.params' |
   'filter:api.video-threads.list.result' |
 
+  'filter:api.video-thread-comments.list.params' |
+  'filter:api.video-thread-comments.list.result' |
+
   'filter:video.auto-blacklist.result'
 
 export type ServerActionHookName =
@@ -30,5 +30,5 @@ export type ServerActionHookName =
 export type ServerHookName = ServerFilterHookName | ServerActionHookName
 
 export interface ServerHook {
-  runHook (hookName: ServerHookName, params?: any)
+  runHook <T> (hookName: ServerHookName, result?: T, params?: any): Promise<T>
 }