Skip to content

Commit ed8c39d

Browse files
committed
minor #14027 Use redirectToRoute (l-vo)
This PR was merged into the 3.4 branch. Discussion ---------- Use redirectToRoute instead of $this->redirect($this->generateUrl('...')) <!-- If your pull request fixes a BUG, use the oldest maintained branch that contains the bug (see https://symfony.com/releases for the list of maintained branches). If your pull request documents a NEW FEATURE, use the same Symfony branch where the feature was introduced (and `master` for features of unreleased versions). --> Commits ------- 964fbda Use redirectToRoute
2 parents 6c11dea + 964fbda commit ed8c39d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

controller/upload_file.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ Finally, you need to update the code of the controller that handles the form::
170170

171171
// ... persist the $product variable or any other work
172172

173-
return $this->redirect($this->generateUrl('app_product_list'));
173+
return $this->redirectToRoute('app_product_list');
174174
}
175175

176176
return $this->render('product/new.html.twig', [

0 commit comments

Comments
 (0)