src/ShopifyApp/Middleware/Billable.php
public function handle(Request $request, Closure $next)
    {
        if (Config::get('shopify-app.billing_enabled') === true) {
            $shop = ShopifyApp::shop();
            if (!$shop->isFreemium() && !$shop->isGrandfathered() && !$shop->plan) {
                // They're not grandfathered in, and there is no charge or charge was declined... redirect to billing
                return Redirect::route('billing');
            }
        }

        // Move on, everything's fine
        return $next($request);
    }
public function handle(Request $request, Closure $next)
    {
        if (Config::get('shopify-app.billing_enabled') === true) {
            $shop = ShopifyApp::shop();
            if (!$shop->isFreemium() && !$shop->isGrandfathered() && !$shop->plan) {
                // They're not grandfathered in, and there is no charge or charge was declined... redirect to billing
                return Redirect::route('billing');
            }
        }

        // Move on, everything's fine
        return $next($request);
    }
Checks if a shop has paid for access.

@param \Illuminate\Http\Request $request
@param \Closure                 $next

@return mixed