diff options
Diffstat (limited to 'lib/oxidized/string.rb')
-rw-r--r-- | lib/oxidized/string.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/oxidized/string.rb b/lib/oxidized/string.rb index 4bdfbf2..8bcb082 100644 --- a/lib/oxidized/string.rb +++ b/lib/oxidized/string.rb @@ -16,7 +16,7 @@ module Oxidized # sets @cmd and @name unless @name is already set def set_cmd command @cmd = command - @name = @cmd.strip.gsub(/\s+/, '_') if @name == nil + @name ||= @cmd.strip.gsub(/\s+/, '_') end def initialize str='' |