update: fix order capacity

This commit is contained in:
tokumeikoi 2022-10-26 21:06:01 +08:00
parent 1a79a7e7f6
commit 44b2d56db9

View File

@ -85,7 +85,7 @@ class OrderController extends Controller
abort(500, __('Subscription plan does not exist'));
}
if (!$planService->haveCapacity() && $request->input('period') !== 'reset_price') {
if ($user->plan_id !== $plan->id && !$planService->haveCapacity() && $request->input('period') !== 'reset_price') {
abort(500, __('Current product is sold out'));
}