diff options
Diffstat (limited to 'lib/shell/command-processor.rb')
-rw-r--r-- | lib/shell/command-processor.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/shell/command-processor.rb b/lib/shell/command-processor.rb index 00357e06fd..5fe6056560 100644 --- a/lib/shell/command-processor.rb +++ b/lib/shell/command-processor.rb @@ -343,7 +343,7 @@ class Shell # %pwd, %cwd -> @pwd def notify(*opts) Shell.notify(*opts) {|mes| - yield mes if iterator? + yield mes if block_given? mes.gsub!("%pwd", "#{@cwd}") mes.gsub!("%cwd", "#{@cwd}") @@ -437,7 +437,7 @@ class Shell ali = ali.id2name if ali.kind_of?(Symbol) command = command.id2name if command.kind_of?(Symbol) begin - if iterator? + if block_given? @alias_map[ali.intern] = proc eval((d = %Q[def #{ali}(*opts) |