NestJS · Middle · Question 30 of 75

How do you implement permission rules more fine-grained than roles, e.g. 'users can edit only their own posts'?

Explanation

Ownership checks often need the loaded resource, so they usually live in the service after fetching it.

Further reading

Problem with a question

NestJS · Middle · question 30

Test yourself

Take the NestJS · Middle quiz: questions and options are shuffled, and you get a review of your mistakes at the end.

Take this quiz