I'm using a "createUserWithEmailAndPassword" method from Firebase and I need to send a context (activity) to it.
But this is inside a Static method (have to be this way because I'm using Fragments.). So, I collect all the data inside the Fragment and send to "registerUser" method in the MainActivity.
So, because this methos (registerUser) is a Static Mode, the MainActivity is not being referenced by the "createUser..." from Firebase.
I've tried to use "This" keyword. I've tried to use "new" keyword, like:
MainActivity main = new MainActivity();
But both does not work and using the "new" keyword, the code is not even compiled.
Someone to help me?