Skip to content

Commit 583c877

Browse files
committed
cleanup billing routes
1 parent 7fbbdbf commit 583c877

1 file changed

Lines changed: 5 additions & 3 deletions

File tree

billing/src/Providers/BillingRoutesProvider.php

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,19 @@
22

33
namespace Boy132\Billing\Providers;
44

5-
use App\Providers\RouteServiceProvider;
65
use Boy132\Billing\Http\Controllers\Api\CheckoutController;
6+
use Illuminate\Foundation\Support\Providers\RouteServiceProvider;
77
use Illuminate\Support\Facades\Route;
88

99
class BillingRoutesProvider extends RouteServiceProvider
1010
{
1111
public function boot(): void
1212
{
1313
$this->routes(function () {
14-
Route::get('checkout/success', [CheckoutController::class, 'success'])->name('billing.checkout.success')->withoutMiddleware(['auth']);
15-
Route::get('checkout/cancel', [CheckoutController::class, 'cancel'])->name('billing.checkout.cancel')->withoutMiddleware(['auth']);
14+
Route::prefix('checkout')->withoutMiddleware(['auth'])->group(function () {
15+
Route::get('/success', [CheckoutController::class, 'success'])->name('billing.checkout.success');
16+
Route::get('/cancel', [CheckoutController::class, 'cancel'])->name('billing.checkout.cancel');
17+
});
1618
});
1719
}
1820
}

0 commit comments

Comments
 (0)