Skip to content

Commit

Permalink
Use url instead of route
Browse files Browse the repository at this point in the history
  • Loading branch information
Gengar-i committed Mar 13, 2024
1 parent 6f36183 commit be163f7
Showing 1 changed file with 4 additions and 11 deletions.
15 changes: 4 additions & 11 deletions src/bundle/Controller/UserSettingsController.php
Original file line number Diff line number Diff line change
Expand Up @@ -112,17 +112,10 @@ public function updateAction(Request $request, UpdateView $view)
]);
}

if ($request->query->has('route')) {
$route = $request->query->get('route');
$contentId = $request->query->get('contentId');
$versionNo = $request->query->get('versionNo');
$language = $request->query->get('language');

return $this->redirectToRoute($route, [
'contentId' => $contentId,
'versionNo' => $versionNo,
'language' => $language,
]);
if ($request->query->has('returnUrl')) {
$returnUrl = $request->query->get('returnUrl');

return $this->redirect($returnUrl);
}

return new RedirectResponse($this->generateUrl('ibexa.user_settings.list'));
Expand Down

0 comments on commit be163f7

Please sign in to comment.