Update PrivacySettings

This commit is contained in:
Daniel Supernault 2019-06-15 23:32:01 -06:00
parent c27c751543
commit 8788bf27db
No known key found for this signature in database
GPG key ID: 0DEF1C662C9033F7

View file

@ -134,16 +134,7 @@ trait PrivacySettings
public function blockedInstanceStore(Request $request)
{
$this->validate($request, [
'domain' => [
'required',
'min:3',
'max:100',
function($attribute, $value, $fail) {
if(!filter_var($value, FILTER_VALIDATE_DOMAIN)) {
$fail($attribute. 'is invalid');
}
}
]
'domain' => 'required|active_url'
]);
$domain = $request->input('domain');
$instance = Instance::firstOrCreate(['domain' => $domain]);