summaryrefslogtreecommitdiff
path: root/lib/shell/system-command.rb
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2019-01-18 09:52:50 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2019-01-18 09:52:50 +0000
commitc20aae965e2e79fcf4c443b266f7012157d5b23b (patch)
tree3b1e6cbcd51d732d05bfd3273c0024c8a9658369 /lib/shell/system-command.rb
parent17aeff3e77e6fe0d37a9943dd93bcb16c4bb9f66 (diff)
Prefer block_given? to iterator?
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66866 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib/shell/system-command.rb')
-rw-r--r--lib/shell/system-command.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/shell/system-command.rb b/lib/shell/system-command.rb
index 767a9ee12c..9d1b07e98c 100644
--- a/lib/shell/system-command.rb
+++ b/lib/shell/system-command.rb
@@ -147,7 +147,7 @@ class Shell
# yorn: Boolean(@shell.debug? or @shell.verbose?)
def notify(*opts)
@shell.notify(*opts) do |mes|
- yield mes if iterator?
+ yield mes if block_given?
mes.gsub!("%id", "#{@command}:##{@pid}")
mes.gsub!("%name", "#{@command}")