What is the correct way to override or extend an auth.js controller in Strapi version 4*? For instance if I wanted to change the text of an error message from “invalid identifier or password” to “invalid email or password” or even adding a phone number to be a new identifier rather than the username field or what have you.
Following the plugin documentation, I’ve created a strapi-server.js file and doing this I know I can add a new route or controller action, but this approach doesn’t seem to be working out too well with what I’m trying to do. Any help would be appreciated.
System Information
- Strapi Version: 4.1.2
- Operating System: macOS Monterrey
- Database: PostgreSQL