From a6c8069aca343382435bf130afc97b1e966a9e40 Mon Sep 17 00:00:00 2001 From: Adrian Hopek Date: Mon, 28 Oct 2024 13:06:05 +0100 Subject: [PATCH] fix --- app/Http/Controllers/UserHistoryController.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Http/Controllers/UserHistoryController.php b/app/Http/Controllers/UserHistoryController.php index f5bf9a80..5e52ae6d 100644 --- a/app/Http/Controllers/UserHistoryController.php +++ b/app/Http/Controllers/UserHistoryController.php @@ -48,7 +48,7 @@ public function store(UserHistoryRequest $request, User $user): RedirectResponse $user->histories()->create($request->data()); return redirect() - ->back("users.history", $user) + ->route("users.history", $user) ->with("success", __("User history created.")); } @@ -81,7 +81,7 @@ public function destroy(UserHistory $history): RedirectResponse $history->delete(); return redirect() - ->back() + ->route("users.history", $history->user_id) ->with("success", __("User history deleted.")); } }