Skip to content

Commit b106e49

Browse files
committed
Escape if all non-letter characters are present
1 parent d171bba commit b106e49

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/components/queryBuilder/utils.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -290,7 +290,7 @@ const getLimit = (limit?: string): string => {
290290

291291
const escapeFields = (fields: string[]): string[] => {
292292
return fields.map((f) => {
293-
return f.match(/(^\d|\s|\$|\&|\|)/im) ? `"${f}"` : f;
293+
return f.match(/(^\d|[^a-zA-Z_])/im) ? `"${f}"` : f;
294294
});
295295
};
296296

0 commit comments

Comments
 (0)