aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/controllers/api/videos/index.ts
diff options
context:
space:
mode:
authorChocobozzz <florian.bigard@gmail.com>2017-08-25 11:45:31 +0200
committerChocobozzz <florian.bigard@gmail.com>2017-08-25 11:45:31 +0200
commit0aef76c479bc7fc758e70e1cd478ade46761b51b (patch)
treeed59eae3ee731c56d25cc35a382f4cc400d0dece /server/controllers/api/videos/index.ts
parent93e1258c7cbc0d1235ca6d2a1f7c1875985328b8 (diff)
downloadPeerTube-0aef76c479bc7fc758e70e1cd478ade46761b51b.tar.gz
PeerTube-0aef76c479bc7fc758e70e1cd478ade46761b51b.tar.zst
PeerTube-0aef76c479bc7fc758e70e1cd478ade46761b51b.zip
Formated -> Formatted
Diffstat (limited to 'server/controllers/api/videos/index.ts')
-rw-r--r--server/controllers/api/videos/index.ts8
1 files changed, 4 insertions, 4 deletions
diff --git a/server/controllers/api/videos/index.ts b/server/controllers/api/videos/index.ts
index d71a132ed..f639df098 100644
--- a/server/controllers/api/videos/index.ts
+++ b/server/controllers/api/videos/index.ts
@@ -36,7 +36,7 @@ import {
36 logger, 36 logger,
37 retryTransactionWrapper, 37 retryTransactionWrapper,
38 generateRandomString, 38 generateRandomString,
39 getFormatedObjects, 39 getFormattedObjects,
40 renamePromise 40 renamePromise
41} from '../../../helpers' 41} from '../../../helpers'
42import { TagInstance } from '../../../models' 42import { TagInstance } from '../../../models'
@@ -386,12 +386,12 @@ function getVideo (req: express.Request, res: express.Response, next: express.Ne
386 } 386 }
387 387
388 // Do not wait the view system 388 // Do not wait the view system
389 res.json(videoInstance.toFormatedJSON()) 389 res.json(videoInstance.toFormattedJSON())
390} 390}
391 391
392function listVideos (req: express.Request, res: express.Response, next: express.NextFunction) { 392function listVideos (req: express.Request, res: express.Response, next: express.NextFunction) {
393 db.Video.listForApi(req.query.start, req.query.count, req.query.sort) 393 db.Video.listForApi(req.query.start, req.query.count, req.query.sort)
394 .then(result => res.json(getFormatedObjects(result.data, result.total))) 394 .then(result => res.json(getFormattedObjects(result.data, result.total)))
395 .catch(err => next(err)) 395 .catch(err => next(err))
396} 396}
397 397
@@ -408,6 +408,6 @@ function removeVideo (req: express.Request, res: express.Response, next: express
408 408
409function searchVideos (req: express.Request, res: express.Response, next: express.NextFunction) { 409function searchVideos (req: express.Request, res: express.Response, next: express.NextFunction) {
410 db.Video.searchAndPopulateAuthorAndPodAndTags(req.params.value, req.query.field, req.query.start, req.query.count, req.query.sort) 410 db.Video.searchAndPopulateAuthorAndPodAndTags(req.params.value, req.query.field, req.query.start, req.query.count, req.query.sort)
411 .then(result => res.json(getFormatedObjects(result.data, result.total))) 411 .then(result => res.json(getFormattedObjects(result.data, result.total)))
412 .catch(err => next(err)) 412 .catch(err => next(err))
413} 413}