lonnieezell / myth-auth

One-stop Auth package for CodeIgniter 4
MIT License
632 stars 207 forks source link

How to disable new account creation without changing $allowRegistration property in vendor? #565

Closed luciocodeigniter closed 1 year ago

luciocodeigniter commented 2 years ago

How to disable new account creation without changing $allowRegistration property in vendor?

manageruz commented 2 years ago

The right way is to extend auth config file inside vendor folder to you app/config folder and name it as auth.php. Then inside this file you may disable $allowRegistration property.

manageruz commented 2 years ago

If you just want to disable registration, the quick way is to remove redistration post route. Of course CI's autorouting must be disabled. After this if someone tries to register, they will see 404 error page. That's all.

manageruz commented 1 year ago

There is no answer from author more than two weeks. Closing it as solved.