Skip to content

Commit

Permalink
fix warning
Browse files Browse the repository at this point in the history
  • Loading branch information
Andrew N Golovkov committed Feb 19, 2016
1 parent b2b8567 commit 0ff83c2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/puppet-lint/plugins/no_symbolic_file_modes.rb
@@ -1,6 +1,6 @@
PuppetLint.new_check(:no_symbolic_file_modes) do

IGNORE_TYPES = Set[:VARIABLE, :UNDEF]
NO_SYMBOLIC_FILE_MODES_IGNORE_TYPES = Set[:VARIABLE, :UNDEF]
WARNING = 'mode should be a 4 digit octal value, not a symbolic mode'

def check
Expand All @@ -11,7 +11,7 @@ def check
}.each do |param_token|
value_token = param_token.next_code_token.next_code_token

break if IGNORE_TYPES.include?(value_token.type)
break if NO_SYMBOLIC_FILE_MODES_IGNORE_TYPES.include?(value_token.type)
break if value_token.value =~ /^[0-7]{4}$/

notify :warning, {
Expand Down

0 comments on commit 0ff83c2

Please sign in to comment.