diff options
author | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2000-09-12 05:37:38 +0000 |
---|---|---|
committer | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2000-09-12 05:37:38 +0000 |
commit | fbcc6dea0c86e7e4d087f1d4b2de19b211d16647 (patch) | |
tree | 68bde87194755712893e5efa4d7f9d2f5312df10 /lib/net/ftp.rb | |
parent | 9d823983dc3e88cb7775c78908a4bb5133ad88ac (diff) |
matz: 1.6.0 final (hopufully)
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@934 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib/net/ftp.rb')
-rw-r--r-- | lib/net/ftp.rb | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/lib/net/ftp.rb b/lib/net/ftp.rb index ab10853bed..7383b003c7 100644 --- a/lib/net/ftp.rb +++ b/lib/net/ftp.rb @@ -276,7 +276,7 @@ module Net end def retrlines(cmd, callback = nil) - if iterator? + if block_given? callback = Proc.new elsif not callback.is_a?(Proc) callback = Proc.new {|line| print line, "\n"} @@ -300,7 +300,7 @@ module Net end def storbinary(cmd, file, blocksize, rest_offset = nil, callback = nil) - if iterator? + if block_given? callback = Proc.new end use_callback = callback.is_a?(Proc) @@ -319,7 +319,7 @@ module Net end def storlines(cmd, file, callback = nil) - if iterator? + if block_given? callback = Proc.new end use_callback = callback.is_a?(Proc) @@ -342,7 +342,7 @@ module Net def getbinaryfile(remotefile, localfile, blocksize = DEFAULT_BLOCKSIZE, callback = nil) - if iterator? + if block_given? callback = Proc.new end use_callback = callback.is_a?(Proc) @@ -365,7 +365,7 @@ module Net end def gettextfile(remotefile, localfile, callback = nil) - if iterator? + if block_given? callback = Proc.new end use_callback = callback.is_a?(Proc) @@ -383,7 +383,7 @@ module Net def putbinaryfile(localfile, remotefile, blocksize = DEFAULT_BLOCKSIZE, callback = nil) - if iterator? + if block_given? callback = Proc.new end use_callback = callback.is_a?(Proc) @@ -404,7 +404,7 @@ module Net end def puttextfile(localfile, remotefile, callback = nil) - if iterator? + if block_given? callback = Proc.new end use_callback = callback.is_a?(Proc) |