forked from Seltcana/rootfs-wip
fix unmount issus when dir is not mount
This commit is contained in:
parent
db8639b893
commit
6ae820e254
@ -234,7 +234,7 @@ class RootFS::RootFS
|
||||
|
||||
def unmount(directory = nil)
|
||||
if directory
|
||||
execute "umount '#{@directory}/#{directory}'"
|
||||
execute "mountpoint -q '#{@directory}/#{directory}' || exit 0 && umount '#{@directory}/#{directory}'"
|
||||
return
|
||||
end
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user