@cords/sdk 0.0.15 → 0.0.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +3 -2
- package/dist/index.mjs +3 -2
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -92,6 +92,7 @@ var CordsAPI = ({
|
|
|
92
92
|
"calculateCityFromSearchString",
|
|
93
93
|
"calculateProvinceFromSearchString"
|
|
94
94
|
]);
|
|
95
|
+
var _a2;
|
|
95
96
|
const url = formatUrl("/search");
|
|
96
97
|
const params = new URLSearchParams({
|
|
97
98
|
q
|
|
@@ -126,9 +127,9 @@ var CordsAPI = ({
|
|
|
126
127
|
);
|
|
127
128
|
}
|
|
128
129
|
}
|
|
129
|
-
if (options.meta.taxonomy) {
|
|
130
|
+
if ((_a2 = options == null ? void 0 : options.meta) == null ? void 0 : _a2.taxonomy) {
|
|
130
131
|
options.meta.taxonomy.forEach((code) => {
|
|
131
|
-
params.append("filter[meta][TaxonomyCodes]", code);
|
|
132
|
+
params.append("filter[meta][TaxonomyCodes][]", code);
|
|
132
133
|
});
|
|
133
134
|
}
|
|
134
135
|
const res = await request(`${url.toString()}?${params}`);
|
package/dist/index.mjs
CHANGED
|
@@ -69,6 +69,7 @@ var CordsAPI = ({
|
|
|
69
69
|
"calculateCityFromSearchString",
|
|
70
70
|
"calculateProvinceFromSearchString"
|
|
71
71
|
]);
|
|
72
|
+
var _a2;
|
|
72
73
|
const url = formatUrl("/search");
|
|
73
74
|
const params = new URLSearchParams({
|
|
74
75
|
q
|
|
@@ -103,9 +104,9 @@ var CordsAPI = ({
|
|
|
103
104
|
);
|
|
104
105
|
}
|
|
105
106
|
}
|
|
106
|
-
if (options.meta.taxonomy) {
|
|
107
|
+
if ((_a2 = options == null ? void 0 : options.meta) == null ? void 0 : _a2.taxonomy) {
|
|
107
108
|
options.meta.taxonomy.forEach((code) => {
|
|
108
|
-
params.append("filter[meta][TaxonomyCodes]", code);
|
|
109
|
+
params.append("filter[meta][TaxonomyCodes][]", code);
|
|
109
110
|
});
|
|
110
111
|
}
|
|
111
112
|
const res = await request(`${url.toString()}?${params}`);
|