Skip to content

Commit 4db0744

Browse files
authored
Merge pull request #265 from devforth/AdminForth/693
fix: fix JSDoc example formatting in IExpressHttpServer interface
2 parents 3b3e91c + a8c8b15 commit 4db0744

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

adminforth/types/Back.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -92,16 +92,16 @@ export interface IExpressHttpServer extends IHttpServer {
9292
* Adds adminUser to request object if user is authorized. Drops request with 401 status if user is not authorized.
9393
* @param callable : Function which will be called if user is authorized.
9494
*
95-
* Example:
9695
*
96+
* @example
9797
* ```ts
98-
* expressApp.get('/myApi', authorize((req, res) => \{
98+
* expressApp.get('/myApi', authorize((req, res) => {
9999
* console.log('User is authorized', req.adminUser);
100-
* res.json(\{ message: 'Hello World' \});
101-
* \}));
100+
* res.json({ message: 'Hello World' });
101+
* }));
102102
* ```
103103
*
104-
*/
104+
*/
105105
authorize(callable: Function): void;
106106
}
107107

0 commit comments

Comments
 (0)