Skip to content

Commit aa63220

Browse files
committed
feat: add backend route prefix configuration and update service providers to use it
1 parent 7243358 commit aa63220

File tree

4 files changed

+4
-3
lines changed

4 files changed

+4
-3
lines changed

config/app.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -125,4 +125,5 @@
125125
'store' => env('APP_MAINTENANCE_STORE', 'database'),
126126
],
127127

128+
'backend_route_prefix' => env('APP_BACKEND_ROUTE_PREFIX', ''),
128129
];

contexts/ArticlePublishing/Infrastructure/ServiceProvider.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ public function boot(): void
4646

4747
public function map(): void
4848
{
49-
Route::middleware('api')->prefix(config('ROUTE_PREFIX'))->group(__DIR__.'/Routes.php');
49+
Route::middleware('api')->prefix(config('app.backend_route_prefix'))->group(__DIR__.'/Routes.php');
5050
}
5151
});
5252

contexts/Authorization/Infrastructure/ServiceProvider.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ public function boot(): void
4040

4141
public function map(): void
4242
{
43-
Route::middleware('api')->prefix(config('ROUTE_PREFIX'))->group(__DIR__.'/Routes.php');
43+
Route::middleware('api')->prefix(config('app.backend_route_prefix'))->group(__DIR__.'/Routes.php');
4444
}
4545
});
4646

contexts/CategoryManagement/Infrastructure/ServiceProvider.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ public function boot(): void
3333

3434
public function map(): void
3535
{
36-
Route::middleware('api')->prefix(config('ROUTE_PREFIX'))->group(__DIR__.'/Routes.php');
36+
Route::middleware('api')->prefix(config('app.backend_route_prefix'))->group(__DIR__.'/Routes.php');
3737
}
3838
});
3939
$this->app->bind(CategoryRepository::class, CategoryPersistence::class);

0 commit comments

Comments
 (0)