summaryrefslogtreecommitdiff
path: root/lib/chef/provider/mount.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/chef/provider/mount.rb')
-rw-r--r--lib/chef/provider/mount.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/chef/provider/mount.rb b/lib/chef/provider/mount.rb
index f8c71c6706..44fb94ca01 100644
--- a/lib/chef/provider/mount.rb
+++ b/lib/chef/provider/mount.rb
@@ -176,7 +176,7 @@ class Chef
# Returns the new_resource device as per device_type
def device_fstab
# Removed "/" from the end of str, because it was causing idempotency issue.
- device = @new_resource.device.chomp("/")
+ device = @new_resource.device == "/" ? @new_resource.device : @new_resource.device.chomp("/")
case @new_resource.device_type
when :device
device