ソースを参照

fix city search for special cars

Olivier Massot 4 年 前
コミット
026a7cd9d2
1 ファイル変更1 行追加1 行削除
  1. 1 1
      components/Ui/Search/Address.vue

+ 1 - 1
components/Ui/Search/Address.vue

@@ -121,7 +121,7 @@ export default Vue.extend({
       let apiUrl = 'https://api-adresse.data.gouv.fr/search/' +
                      `?type=${this.type}` +
                      `&autocomplete=${this.autocomplete ? 1 : 0}` +
-                     `&q=${encodeURI(val.replace(/\s+/gi, '+'))}`
+                     `&q=${val.replace(/[\s&?]/gi, '+')}`
 
       if (this.limit > 0) {
         apiUrl += `&limit=${this.limit}`