|
@@ -39,6 +39,7 @@ class RegisterController extends Controller
|
|
public function __construct()
|
|
public function __construct()
|
|
{
|
|
{
|
|
$this->middleware('guest');
|
|
$this->middleware('guest');
|
|
|
|
+ $this->openRegistrationCheck();
|
|
}
|
|
}
|
|
|
|
|
|
/**
|
|
/**
|
|
@@ -83,4 +84,12 @@ class RegisterController extends Controller
|
|
return abort(403);
|
|
return abort(403);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ public function openRegistrationCheck()
|
|
|
|
+ {
|
|
|
|
+ $openRegistration = config('pixelfed.open_registration');
|
|
|
|
+ if(false == $openRegistration) {
|
|
|
|
+ abort(403);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
}
|
|
}
|