Skip to content

Commit 88c4b4e

Browse files
author
Pierre Villette
committed
Better handling of languages prefix in the search location
1 parent 5fe9c15 commit 88c4b4e

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

templates/apps/drupal/drupal.j2

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,6 +134,11 @@ location / {
134134
location ~* ^(?:\/(?:{{ nginx_drupal_language_path_prefixes|join('|') }}))?\/sitemap\.xml$ {
135135
try_files $uri @drupal-no-args;
136136
}
137+
138+
## Core search support.
139+
location ~* ^(?:\/(?:{{ nginx_drupal_language_path_prefixes|join('|') }}))?\/search/.+/.+ {
140+
try_files $uri @drupal-no-args;
141+
}
137142
{% endif %}
138143

139144
## All static files will be served directly.
@@ -152,7 +157,7 @@ location / {
152157
}
153158

154159
## Core search support.
155-
location ~* (/[[:alpha:]-]+)?/search/.+/.+ {
160+
location ~* ^/search/.+/.+ {
156161
try_files $uri @drupal-no-args;
157162
}
158163

0 commit comments

Comments
 (0)