Permalink
Browse files

Improve empty string check

  • Loading branch information...
1 parent d783482 commit 2f701298b70a3d787c43eac9f86b17b2a44d2010 @igorsobreira committed Mar 13, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 lib/vagrant-screenshot/screenshot_command.rb
@@ -9,7 +9,7 @@ def execute
options = {}
filenames = []
- raise Errors::VBoxManageCommandNotFound if vbox_manage_command == ""
+ raise Errors::VBoxManageCommandNotFound if vbox_manage_command.empty?
opts = build_screenshot_options options
argv = parse_options(opts)
@@ -47,7 +47,7 @@ def build_screenshot_options(options)
opts.banner = "Take screenshot from all active VMs.\n\n"
opts.banner += "Usage: vagrant screenshot [vm-name1, vm-name2, ...]\n\n"
- if open_command != ""
+ if !open_command.empty?
opts.on("-o", "--open", "Opens the generated images") do |c|
options[:open] = true
end

0 comments on commit 2f70129

Please sign in to comment.