Bugfix/add missing permission guard in create watchlist item endpoint (#4686)
* Add missing permission guard * Update changelog
This commit is contained in:
parent
b6e8431c53
commit
480709c32a
@ -18,6 +18,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|||||||
- Improved the language localization for Italian (`it`)
|
- Improved the language localization for Italian (`it`)
|
||||||
- Upgraded `nestjs` from version `10.4.15` to `11.0.12`
|
- Upgraded `nestjs` from version `10.4.15` to `11.0.12`
|
||||||
|
|
||||||
|
### Fixed
|
||||||
|
|
||||||
|
- Fixed an issue in the watchlist endpoint (`POST`) related to the `HasPermissionGuard`
|
||||||
|
|
||||||
## 2.161.0 - 2025-05-06
|
## 2.161.0 - 2025-05-06
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
|
@ -39,7 +39,7 @@ export class WatchlistController {
|
|||||||
|
|
||||||
@Post()
|
@Post()
|
||||||
@HasPermission(permissions.createWatchlistItem)
|
@HasPermission(permissions.createWatchlistItem)
|
||||||
@UseGuards(AuthGuard('jwt'))
|
@UseGuards(AuthGuard('jwt'), HasPermissionGuard)
|
||||||
@UseInterceptors(TransformDataSourceInRequestInterceptor)
|
@UseInterceptors(TransformDataSourceInRequestInterceptor)
|
||||||
public async createWatchlistItem(@Body() data: CreateWatchlistItemDto) {
|
public async createWatchlistItem(@Body() data: CreateWatchlistItemDto) {
|
||||||
return this.watchlistService.createWatchlistItem({
|
return this.watchlistService.createWatchlistItem({
|
||||||
|
Loading…
x
Reference in New Issue
Block a user