Welcome Guest, Not a member yet? Register   Sign In
Problem with instances in Myth-auth
#1

Hi,


1. I use myth/auth in my CI4 app
2. I have imported all myth/auth/config/* classes into app/config directory (also Auth and Services). 
3. Method passwords() in the class Services (which is in app/config/ now) returns PasswordValidator class with argument of Auth class.
4. PasswordValidator is internal class in the myth/auth package.
5. The problem is:  PasswordValidator expects myth/auth/config/Auth class while it receives app/config/Auth class.
6. What is the best method to solve it?
a) I could use myth/auth/config/Auth instance, but it is not a perfect solution because I need to maintain a class inside the package from vendor with my customized data (problems after upgrade)
b) I could modify PasswordValidator to accept app/config/Auth instance, but it is a similar problem with upgrades

So my question is: is there an elegant solution for problem like that? 

Thanks and best greetings!
Reply
#2

It was meant to be installed as a separate module.
What did you Try? What did you Get? What did you Expect?

Joined CodeIgniter Community 2009.  ( Skype: insitfx )
Reply




Theme © iAndrew 2016 - Forum software by © MyBB