Update config var

This commit is contained in:
Daniel Supernault 2019-06-09 17:48:27 -06:00
parent 29022c6a79
commit 9879d3c942
No known key found for this signature in database
GPG key ID: 0DEF1C662C9033F7
2 changed files with 3 additions and 5 deletions

View file

@ -40,7 +40,7 @@ class ApiController extends BaseApiController
'activitypub' => [ 'activitypub' => [
'enabled' => config('federation.activitypub.enabled'), 'enabled' => config('federation.activitypub.enabled'),
'remote_follow' => config('pixelfed.remote_follow_enabled') 'remote_follow' => config('federation.activitypub.remoteFollow')
], ],
'ab' => [ 'ab' => [

View file

@ -51,15 +51,13 @@ class FederationController extends Controller
public function remoteFollowStore(Request $request) public function remoteFollowStore(Request $request)
{ {
return; return;
$this->authCheck(); $this->authCheck();
$this->validate($request, [ $this->validate($request, [
'url' => 'required|string', 'url' => 'required|string',
]); ]);
if (config('pixelfed.remote_follow_enabled') !== true) { abort_if(!config('federation.activitypub.remoteFollow'), 403);
abort(403);
}
$follower = Auth::user()->profile; $follower = Auth::user()->profile;
$url = $request->input('url'); $url = $request->input('url');