Override "auth.js" and "user.js" (in "controllers") within "plugin-users-permissions" completely 🤔

System Information
  • Strapi Version: 4.21.1
  • Operating System: Heroku
  • Database: PostgreSQL
  • Node Version: 18.20.0
  • NPM Version: >=6.0.0

Hello guys,

I have extensively modified the files “auth.js” and “user.js” (in “controllers”) within “plugin-users-permissions”, and I have bound them via “strapi-server.js”.


Here are the two files with which I want to completely override the system functions:


But the program is not running yet because the following two lines are not functioning:


Could someone perhaps give me a tip on how to write this part correctly? :thinking:

Many thanks in advance!

I solved the problem myself by copying and adding more files from the original.