Skip to content

Commit 437209e

Browse files
committed
2 parents d615bfe + 97649b4 commit 437209e

File tree

3 files changed

+11
-10
lines changed

3 files changed

+11
-10
lines changed

.npmrc

Whitespace-only changes.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@7span/directus-extension-custom-query-panel",
3-
"version": "1.1.5",
3+
"version": "1.1.6",
44
"scripts": {
55
"build": "directus-extension build",
66
"dev": "directus-extension build -w --no-minify",

src/custom-query/index.js

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -74,15 +74,16 @@ function prepareVariables(variables) {
7474
const preparedVariables = {};
7575
variables.forEach((item) => {
7676
const { key, value } = item;
77-
if (Number.isInteger(value)) {
78-
preparedVariables[key] = `${parseInt(value)}`;
79-
} else if (!isNaN(parseFloat(value))) {
80-
preparedVariables[key] = `${parseFloat(value)}`;
81-
} else if (typeof value === "string") {
82-
preparedVariables[key] = `'${value}'`;
83-
} else {
84-
console.log(`Unsupported data type for key ${key}`)
85-
}
77+
preparedVariables[key] = value
78+
// if (Number.isInteger(value)) {
79+
// preparedVariables[key] = `${parseInt(value)}`;
80+
// } else if (!isNaN(parseFloat(value))) {
81+
// preparedVariables[key] = `${parseFloat(value)}`;
82+
// } else if (typeof value === "string") {
83+
// preparedVariables[key] = `'${value}'`;
84+
// } else {
85+
// console.log(`Unsupported data type for key ${key}`)
86+
// }
8687
});
8788
return preparedVariables;
8889
}

0 commit comments

Comments
 (0)