lib/pre-commit/checks/console_log.rb in pre-commit-0.1.4 vs lib/pre-commit/checks/console_log.rb in pre-commit-0.1.5
- old
+ new
@@ -23,13 +23,13 @@
true
end
end
def detected_bad_code?
- system("grep -q 'console.log' #{staged_files}")
+ system("grep -qe \"console\\.log\" #{staged_files}")
end
def instances_of_console_log_violations
- `grep -nH 'console.log' #{staged_files}`
+ `grep -nHe \"console\\.log\" #{staged_files}`
end
end