diff options
Diffstat (limited to 'server/middlewares')
-rw-r--r-- | server/middlewares/doc.ts | 2 | ||||
-rw-r--r-- | server/middlewares/error.ts | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/server/middlewares/doc.ts b/server/middlewares/doc.ts index eef76acaa..c43f41977 100644 --- a/server/middlewares/doc.ts +++ b/server/middlewares/doc.ts | |||
@@ -5,7 +5,7 @@ function openapiOperationDoc (options: { | |||
5 | operationId?: string | 5 | operationId?: string |
6 | }) { | 6 | }) { |
7 | return (req: express.Request, res: express.Response, next: express.NextFunction) => { | 7 | return (req: express.Request, res: express.Response, next: express.NextFunction) => { |
8 | res.locals.docUrl = options.url || 'https://docs.joinpeertube.org/api-rest-reference.html#operation/' + options.operationId | 8 | res.locals.docUrl = options.url || 'https://docs.joinpeertube.org/api/rest-reference.html#operation/' + options.operationId |
9 | 9 | ||
10 | if (next) return next() | 10 | if (next) return next() |
11 | } | 11 | } |
diff --git a/server/middlewares/error.ts b/server/middlewares/error.ts index 96a85012a..7b116eb57 100644 --- a/server/middlewares/error.ts +++ b/server/middlewares/error.ts | |||
@@ -28,7 +28,7 @@ function apiFailMiddleware (req: express.Request, res: express.Response, next: e | |||
28 | detail: message, | 28 | detail: message, |
29 | 29 | ||
30 | type: type | 30 | type: type |
31 | ? `https://docs.joinpeertube.org/api-rest-reference.html#section/Errors/${type}` | 31 | ? `https://docs.joinpeertube.org/api/rest-reference.html#section/Errors/${type}` |
32 | : undefined | 32 | : undefined |
33 | }, extension) | 33 | }, extension) |
34 | 34 | ||