Skip to content

Commit 178cd82

Browse files
bug #773 fix(autocomplete): Use absolute path to generate next page url (syl20b)
This PR was merged into the 2.x branch. Discussion ---------- fix(autocomplete): Use absolute path to generate next page url | Q | A | ------------- | --- | Bug fix? | yes | New feature? | no | Tickets | Fix #772 | License | MIT This will generate `next_page` URL based on absolute path instead of absolute URL. <!-- Replace this notice by a short README for your feature/bugfix. This will help people understand your PR and can be used as a start for the documentation. Additionally (see https://symfony.com/releases): - Always add tests and ensure they pass. - Never break backward compatibility (see https://symfony.com/bc). - Features and deprecations must be submitted against branch main. --> Commits ------- db65a13c fix(autocomplete): Use absolute path to generate next page url
2 parents 9d2d49d + fd7659a commit 178cd82

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Autocomplete/src/Controller/EntityAutocompleteController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ public function __invoke(string $alias, Request $request): Response
4646
if ($data->hasNextPage) {
4747
$parameters = array_merge($request->attributes->all('_route_params'), $request->query->all(), ['page' => $page + 1]);
4848

49-
$nextPage = $this->urlGenerator->generate($request->attributes->get('_route'), $parameters, UrlGeneratorInterface::ABSOLUTE_URL);
49+
$nextPage = $this->urlGenerator->generate($request->attributes->get('_route'), $parameters);
5050
}
5151

5252
return new JsonResponse([

0 commit comments

Comments
 (0)