diff options
author | Lamont Granquist <lamont@scriptkiddie.org> | 2015-12-10 18:25:44 -0800 |
---|---|---|
committer | Lamont Granquist <lamont@scriptkiddie.org> | 2015-12-14 12:51:58 -0800 |
commit | 27cb74bc5983b31ddbc9de46c8e020122251abe7 (patch) | |
tree | b5537c9a860f94c1d435865ff3bc9662a07c5d8a | |
parent | 469210218eaac8f38e9062c61a49a86a1e4a69fa (diff) | |
download | chef-27cb74bc5983b31ddbc9de46c8e020122251abe7.tar.gz |
convert to true/false/nil in properties
-rw-r--r-- | lib/chef/resource/file.rb | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/lib/chef/resource/file.rb b/lib/chef/resource/file.rb index 9db53b991a..80fae1b4dc 100644 --- a/lib/chef/resource/file.rb +++ b/lib/chef/resource/file.rb @@ -55,14 +55,14 @@ class Chef @verifications = [] end - property :content, [ String, NilClass ], desired_state: false - property :backup, [ Integer, FalseClass ], desired_state: false, default: 5 - property :checksum, [ String, NilClass ], is: /^[a-zA-Z0-9]{64}$/ + property :content, [ String, nil ], desired_state: false + property :backup, [ Integer, false ], desired_state: false, default: 5 + property :checksum, [ String, nil ], is: /^[a-zA-Z0-9]{64}$/ property :path, [ String ], name_property: true - property :diff, [ String, NilClass ], desired_state: false - property :atomic_update, [ TrueClass, FalseClass ], desired_state: false, default: Chef::Config[:file_atomic_update] - property :force_unlink, [ TrueClass, FalseClass ], desired_state: false, default: false - property :manage_symlink_source, [ TrueClass, FalseClass ], desired_state: false + property :diff, [ String, nil ], desired_state: false + property :atomic_update, [ true, false ], desired_state: false, default: Chef::Config[:file_atomic_update] + property :force_unlink, [ true, false ], desired_state: false, default: false + property :manage_symlink_source, [ true, false ], desired_state: false def verify(command=nil, opts={}, &block) if ! (command.nil? || [String, Symbol].include?(command.class)) |