Get 500 error on client side but 403 in terminal for the backend

Might be helpful to someone but I suddenly developed this issue when I created a plugin and imported ApplicationError from @strapi/utils - it broke error handling which was previously working perfectly. I was able to fix this issue by explicitly installing @strapi/utils in my project even though it was already in the node_modules folder.

Strapi version 4.6.1