From fb2fe61daff0a9fd1e664cbca932062db2fa3bc8 Mon Sep 17 00:00:00 2001 From: snipe Date: Wed, 10 Aug 2022 15:03:26 -0700 Subject: [PATCH] Use a less stupid URL for this endpoint Signed-off-by: snipe --- routes/api.php | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/routes/api.php b/routes/api.php index 1a0a80642a..efeffc6505 100644 --- a/routes/api.php +++ b/routes/api.php @@ -280,13 +280,22 @@ Route::group(['prefix' => 'v1', 'middleware' => ['api', 'throttle:api']], functi ] )->name('api.consumables.selectlist'); - Route::get('view/{id}/users', + Route::get('{id}/users', [ Api\ConsumablesController::class, 'getDataView' ] )->name('api.consumables.showUsers'); + + // This is LEGACY endpoint URL and should be removed in the next major release + Route::get('view/{id}/users', + [ + Api\ConsumablesController::class, + 'getDataView' + ] + )->name('api.consumables.showUsers'); + Route::post('{consumable}/checkout', [ Api\ConsumablesController::class,