1 year ago

Spark::checkPlanEligibilityUsing Not Firing

Posted 1 year ago by thechrise

I'm placing this in the SparkServiveProvider booted function. And I have a Website model that is connected to the team and I can get a count of 1, but even when I use this method without the if statement, and just return false, it's not blocking the subscription downgrade or upgrade. Any help would be much appreciated.

Spark::checkPlanEligibilityUsing(function ($user, $plan) {
            if ($plan->name == 'medium' && count($user->currentTeam->websites) > 0) {
                return false;

            return true;

Please sign in or create an account to participate in this conversation.