diff --git a/scripts/solhint-custom/index.js b/scripts/solhint-custom/index.js index 9625027eefe..34eac353f36 100644 --- a/scripts/solhint-custom/index.js +++ b/scripts/solhint-custom/index.js @@ -48,8 +48,8 @@ module.exports = [ VariableDeclaration(node) { if (node.isDeclaredConst) { - // TODO: expand visibility and fix - if (node.visibility === 'private' && /^_/.test(node.name)) { + // Check all constant variables regardless of visibility + if (/^_/.test(node.name)) { this.error(node, 'Constant variables should not have leading underscore'); } } else if (node.visibility === 'private' && !/^_/.test(node.name)) {