kopia lustrzana https://github.com/pixelfed/pixelfed
Update StatusController
rodzic
72272d8f09
commit
a5019b8907
|
@ -74,7 +74,10 @@ class StatusController extends Controller
|
||||||
return redirect('/login?next='.urlencode('/' . $request->path()));
|
return redirect('/login?next='.urlencode('/' . $request->path()));
|
||||||
}
|
}
|
||||||
$id = HashidService::decode($id);
|
$id = HashidService::decode($id);
|
||||||
$status = Status::findOrFail($id);
|
$status = Status::find($id);
|
||||||
|
if(!$status) {
|
||||||
|
return redirect('/404');
|
||||||
|
}
|
||||||
return redirect($status->url());
|
return redirect($status->url());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -115,8 +115,6 @@ class StatusDelete implements ShouldQueue
|
||||||
$tag->delete();
|
$tag->delete();
|
||||||
});
|
});
|
||||||
|
|
||||||
MediaTag::whereStatusId($status->id)
|
|
||||||
->get();
|
|
||||||
$status->forceDelete();
|
$status->forceDelete();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
Ładowanie…
Reference in New Issue