mirror of
https://github.com/pixelfed/pixelfed.git
synced 2024-11-14 02:24:31 +00:00
Update ProfileController, revert pgsql change
This commit is contained in:
parent
1536e0f006
commit
db46f7ddbb
1 changed files with 2 additions and 5 deletions
|
@ -22,14 +22,11 @@ class ProfileController extends Controller
|
||||||
{
|
{
|
||||||
public function show(Request $request, $username)
|
public function show(Request $request, $username)
|
||||||
{
|
{
|
||||||
if(config('database.default') == 'pgsql') {
|
|
||||||
$username = strtolower($username);
|
|
||||||
}
|
|
||||||
|
|
||||||
$user = Profile::whereNull('domain')
|
$user = Profile::whereNull('domain')
|
||||||
->whereNull('status')
|
->whereNull('status')
|
||||||
->whereUsername($username)
|
->whereUsername($username)
|
||||||
->firstOrFail();
|
->firstOrFail();
|
||||||
|
|
||||||
if($request->wantsJson() && config('federation.activitypub.enabled')) {
|
if($request->wantsJson() && config('federation.activitypub.enabled')) {
|
||||||
return $this->showActivityPub($request, $user);
|
return $this->showActivityPub($request, $user);
|
||||||
}
|
}
|
||||||
|
@ -247,6 +244,6 @@ class ProfileController extends Controller
|
||||||
->where('expires_at', '>', now())
|
->where('expires_at', '>', now())
|
||||||
->count();
|
->count();
|
||||||
abort_unless($exists > 0, 404);
|
abort_unless($exists > 0, 404);
|
||||||
return view('profile.story', compact('pid'));
|
return view('profile.story', compact('pid', 'profile'));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue