You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In step 7 of documentation link above, under title: Restricting content access with an "is-owner policy", the steps to ensuring the methods to which middleware should apply is probably wrong.
After failing to see a log after adding a method read, I went to typescript types and tried find which worked.
I added some additional context and suggested fixes. let me know if you need further information.
Either there was a change in another version which I am not using, maybe later versions use read instead of find, in which case, I am not sure how this could be solved, maybe a version switcher (example: https://laravel.com/docs/11.x/readme) at top is too big of a topic.
If not, just updating it should solve the issue I faced.
Related issue(s)/PR(s)
No response
The text was updated successfully, but these errors were encountered:
Link to the documentation page or resource
https://docs.strapi.io/dev-docs/backend-customization/middlewares#restricting-content-access-with-an-is-owner-policy
Describe the bug
In step 7 of documentation link above, under title:
Restricting content access with an "is-owner policy"
, the steps to ensuring the methods to which middleware should apply is probably wrong.After failing to see a log after adding a method
read
, I went to typescript types and triedfind
which worked.I added some additional context and suggested fixes. let me know if you need further information.
ps.
I am probably using @strapi/strapi@4.12.4
Additional context
The route config I used to find this information was in node modules. I tried finding it in github but I don't think I can find a generated type in the monorepo, only relevant file was in a commit which may have been moved/renamed/etc.
https://github.com/strapi/strapi/blob/9c79921d22142a5de77ea26151550a14e4b12669/packages/core/types/src/types/core-api/router.ts#L29
Below is how it looks in my node modules.
Suggested improvements or fixes
Either there was a change in another version which I am not using, maybe later versions use read instead of find, in which case, I am not sure how this could be solved, maybe a version switcher (example: https://laravel.com/docs/11.x/readme) at top is too big of a topic.
If not, just updating it should solve the issue I faced.
Related issue(s)/PR(s)
No response
The text was updated successfully, but these errors were encountered: