We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 078f793 commit 92ba227Copy full SHA for 92ba227
src/rules/prefer-in-document.js
@@ -125,7 +125,7 @@ export const create = (context) => {
125
const sourceCode = context.getSourceCode();
126
const token = sourceCode.getTokenAfter(argument);
127
if (token.value === "," && token.type === "Punctuator") {
128
- // Remove commas if toHaveLength had more than one argument
+ // Remove commas if toHaveLength had more than one argument or a trailing comma
129
operations.push(fixer.replaceText(token, ""));
130
}
131
operations.push(fixer.remove(argument));
0 commit comments