Permalink
Browse files

* cosmetic.

  • Loading branch information...
1 parent 14104a4 commit bb5ed6c7a53d9d47d90fb5b663bd74427764d21f nahi committed Dec 25, 2008
Showing with 2 additions and 3 deletions.
  1. +2 −3 bench/bm_upload.rb
View
@@ -1,6 +1,5 @@
require 'bm_common'
-
-require 'multipart'
+try_require 'multipart'
url = ARGV.shift or raise
proxy = ENV['http_proxy'] || ENV['HTTP_PROXY']
@@ -92,7 +91,7 @@ def do_threads(number)
end
=end
- if defined?(Net::HTTP)
+ if defined?(Net::HTTP) and defined?(Net::HTTP::FileForPost)
bm.report('Net::HTTP + multipart') do
do_threads(threads) {
if proxy

0 comments on commit bb5ed6c

Please sign in to comment.