feat: Add token-based authorization to category deletion and enhance user registration with error handling and audit logging.
This commit is contained in:
parent
45941fbe6c
commit
af14610442
16 changed files with 1003 additions and 236 deletions
|
|
@ -45,6 +45,6 @@ export class CategoriesAdminController {
|
|||
@Response('401', 'Invalid or expired token')
|
||||
public async deleteCategory(@Request() request: any, @Path() id: number): Promise<deleteCategoryResponse> {
|
||||
const token = request.headers.authorization?.replace('Bearer ', '') || '';
|
||||
return await this.categoryService.deleteCategory(id);
|
||||
return await this.categoryService.deleteCategory(token,id);
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue