diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/chef/util/file_edit.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/chef/util/file_edit.rb b/lib/chef/util/file_edit.rb index ea0a523baa..3f354124b3 100644 --- a/lib/chef/util/file_edit.rb +++ b/lib/chef/util/file_edit.rb @@ -33,7 +33,7 @@ class Chef @file_edited = false raise ArgumentError, "File doesn't exist" unless File.exist? @original_pathname - @contents = File.new(@original_pathname).readlines + @contents = File.new(@original_pathname){ |f| f.readlines } end #search the file line by line and match each line with the given regex |