Closed mehrdad-shokri closed 6 years ago
You could use the Invite model.
use Clarkeash\Doorman\Models\Invite;
$invite = Invite::where('code', 'ENTER INVITE CODE HERE')->firstOrFail();
$email = $invite->for; // could be null
Does this help at all?
yep, copied some method sources to the controller since it's protected and cant be called from the facade.
Why you Str::toUpper
invite code when looking up for invite code in the source code?
I have generated an invite code for an email. Now I just want that if a givven invite code is available( is not expired, is not used yet, etc.) without passing the associated email.
Is there any method for doing so?
The purpose behind this is that I email invite codes generated for that email so asking for email is redundant.
Also, I want to find associated email instead of asking them.
The question is how to validate invite codes without passing email address?