From 93cf3511682fd16580f5e75e85676339275e8aa8 Mon Sep 17 00:00:00 2001 From: Daniel Supernault Date: Mon, 20 May 2019 21:50:06 -0600 Subject: [PATCH] Update ProfileController --- app/Http/Controllers/ProfileController.php | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/app/Http/Controllers/ProfileController.php b/app/Http/Controllers/ProfileController.php index 3d256e0c..52201dad 100644 --- a/app/Http/Controllers/ProfileController.php +++ b/app/Http/Controllers/ProfileController.php @@ -19,7 +19,10 @@ class ProfileController extends Controller { public function show(Request $request, $username) { - $user = Profile::whereNull('domain')->whereUsername($username)->firstOrFail(); + $user = Profile::whereUsername($username)->firstOrFail(); + if($user->domain) { + return redirect($user->remote_url); + } if($user->status != null) { return $this->accountCheck($user); } else { @@ -252,12 +255,4 @@ class ProfileController extends Controller return view('profile.bookmarks', compact('user', 'profile', 'settings', 'owner', 'following', 'timeline', 'is_following', 'is_admin')); } - public function createCollection(Request $request) - { - } - - - public function collections(Request $request) - { - } }