Skip to content

Conversation

@aman2519
Copy link
Contributor

Fixes issue #65

@niamccash niamccash self-assigned this Oct 13, 2023
@niamccash
Copy link
Contributor

Hi @aman2519

First of all, this is one of the more difficult checks to create so kudos to you for taking it on!

Your regex needs to be modified. Looks like the Linter check is looking for occurrences where the display value (the third parameter) IS provided and identify that as a finding.

We want to find and identify cases of:
g_form.getValue('reference_field', 'sys_id"); // <-- this does not follow recommended practice and should be fixed

not of:
g_form.getValue('reference_field', 'sys_id', 'display value'); // <-- because this already follows recommended practice

@aman2519
Copy link
Contributor Author

aman2519 commented Oct 13, 2023

@niamccash Good catch, probably friday fever has taken over.
Updated the script, kindly validate.

@niamccash niamccash merged commit 3bd08fd into ServiceNowDevProgram:master Oct 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants