exguard-backend 1.0.13 → 1.0.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/scripts/setup-nestjs.cjs +1 -1
package/package.json
CHANGED
package/scripts/setup-nestjs.cjs
CHANGED
|
@@ -370,9 +370,9 @@ import {
|
|
|
370
370
|
} from '../exguard/exguard.guard';
|
|
371
371
|
|
|
372
372
|
@Controller('events')
|
|
373
|
-
@UseGuards(ExGuardPermissionGuard) // Requires 'read' permission
|
|
374
373
|
export class EventsController {
|
|
375
374
|
@Get()
|
|
375
|
+
@UseGuards(createPermissionGuard(['events:read']))
|
|
376
376
|
async getEvents(@Request() req) {
|
|
377
377
|
console.log('User accessing events:', req.user);
|
|
378
378
|
console.log('User permissions:', req.user?.permissions);
|