Dec 16, 2019
6
Level 5
Force Route::group(['domain'=>'external.com']) to return https-prefixed routes
Hello everybody,
I created a new routes definition called external.php.
This is how it looks like:
Route::group([
'domain' => 'example.org'
], function () {
Route::post('oauth/token')->name('external.oauth.token');
This works fine, so php artisan route:list contains:
| example.org | POST | oauth/token | external.oauth.token | Closure | |
If I do route('external.oauth.token') I am getting this result:
"http://example.org/oauth/token"
So my question is: How can I force the route to be secure/with https-prefix?
Level 73
Please or to participate in this conversation.