From 9cdbacdf58fd7aa57f2f70bfb64a0b1848bc25dc Mon Sep 17 00:00:00 2001 From: Lawrence Garcia <65413418+lawrenceee04@users.noreply.github.com> Date: Tue, 17 Dec 2024 21:18:25 +0800 Subject: [PATCH] Update web.php --- routes/api.php | 6 ++++++ routes/web.php | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/routes/api.php b/routes/api.php index 889937e..1b0f42c 100644 --- a/routes/api.php +++ b/routes/api.php @@ -1,7 +1,9 @@ get('/user', function (Request $request) { return $request->user(); }); diff --git a/routes/web.php b/routes/web.php index 89f81cc..6bc3e0d 100644 --- a/routes/web.php +++ b/routes/web.php @@ -4,7 +4,9 @@ use App\Http\Controllers\DashboardController; use App\Http\Controllers\ProfileController; use App\Http\Controllers\VisitController; +use Illuminate\Support\Facades\App; use Illuminate\Support\Facades\Route; +use Illuminate\Support\Facades\URL; /* |-------------------------------------------------------------------------- @@ -17,6 +19,10 @@ |ob */ +if (App::environment('production')) { + URL::forceScheme('https'); +}; + Route::get('/', function () { return view('welcome'); });