We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b02eec0 commit 146bb02Copy full SHA for 146bb02
src/fieldsConverter.ts
@@ -395,7 +395,7 @@ export function enumToGraphQL(
395
} else if (value === '') {
396
key = 'EMPTY_STRING';
397
} else {
398
- if (typeof value.toString === 'function') {
+ if (typeof value?.replace === 'function') {
399
key = value?.replace(/[^_a-zA-Z0-9]/g, '_')?.replace(/(^[0-9])(.*)/g, 'a_$1$2');
400
401
key = value;
0 commit comments