aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/models/video-blacklist.ts
diff options
context:
space:
mode:
authorChocobozzz <florian.bigard@gmail.com>2017-06-10 22:15:25 +0200
committerChocobozzz <florian.bigard@gmail.com>2017-06-10 22:15:25 +0200
commit69818c9394366b954b6ba3bd697bd9d2b09f2a16 (patch)
treead199a18ec3c322460d6f9523fc383ee562554e0 /server/models/video-blacklist.ts
parent4d4e5cd4dca78480ec7f40e747f424cd107376a4 (diff)
downloadPeerTube-69818c9394366b954b6ba3bd697bd9d2b09f2a16.tar.gz
PeerTube-69818c9394366b954b6ba3bd697bd9d2b09f2a16.tar.zst
PeerTube-69818c9394366b954b6ba3bd697bd9d2b09f2a16.zip
Type functions
Diffstat (limited to 'server/models/video-blacklist.ts')
-rw-r--r--server/models/video-blacklist.ts10
1 files changed, 5 insertions, 5 deletions
diff --git a/server/models/video-blacklist.ts b/server/models/video-blacklist.ts
index fe72d5d46..f36756085 100644
--- a/server/models/video-blacklist.ts
+++ b/server/models/video-blacklist.ts
@@ -66,15 +66,15 @@ function associate (models) {
66 }) 66 })
67} 67}
68 68
69countTotal = function (callback) { 69countTotal = function (callback: BlacklistedVideoMethods.CountTotalCallback) {
70 return BlacklistedVideo.count().asCallback(callback) 70 return BlacklistedVideo.count().asCallback(callback)
71} 71}
72 72
73list = function (callback) { 73list = function (callback: BlacklistedVideoMethods.ListCallback) {
74 return BlacklistedVideo.findAll().asCallback(callback) 74 return BlacklistedVideo.findAll().asCallback(callback)
75} 75}
76 76
77listForApi = function (start, count, sort, callback) { 77listForApi = function (start: number, count: number, sort: string, callback: BlacklistedVideoMethods.ListForApiCallback) {
78 const query = { 78 const query = {
79 offset: start, 79 offset: start,
80 limit: count, 80 limit: count,
@@ -88,11 +88,11 @@ listForApi = function (start, count, sort, callback) {
88 }) 88 })
89} 89}
90 90
91loadById = function (id, callback) { 91loadById = function (id: number, callback: BlacklistedVideoMethods.LoadByIdCallback) {
92 return BlacklistedVideo.findById(id).asCallback(callback) 92 return BlacklistedVideo.findById(id).asCallback(callback)
93} 93}
94 94
95loadByVideoId = function (id, callback) { 95loadByVideoId = function (id: string, callback: BlacklistedVideoMethods.LoadByIdCallback) {
96 const query = { 96 const query = {
97 where: { 97 where: {
98 videoId: id 98 videoId: id