More test fixes

Signed-off-by: snipe <snipe@snipe.net>
This commit is contained in:
snipe
2025-02-19 06:19:50 +00:00
parent 347eb2bdee
commit cd7135ea77
7 changed files with 18 additions and 26 deletions
@@ -26,14 +26,10 @@ class StatuslabelsController extends Controller
return view('statuslabels.index');
}
public function show($id) : View | RedirectResponse
public function show(Statuslabel $statuslabel) : View | RedirectResponse
{
$this->authorize('view', Statuslabel::class);
if ($statuslabel = Statuslabel::find($id)) {
return view('statuslabels.view')->with('statuslabel', $statuslabel);
}
return redirect()->route('statuslabels.index')->with('error', trans('admin/statuslabels/message.does_not_exist'));
return view('statuslabels.view')->with('statuslabel', $statuslabel);
}
/**