fix bug

Andrew Cantino 11 年之前
父節點
當前提交
7d5e10aff4
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      app/models/agents/post_agent.rb

+ 1 - 1
app/models/agents/post_agent.rb

@@ -47,7 +47,7 @@ module Agents
47 47
     private
48 48
 
49 49
     def post_data(data)
50
-      uri = URI.new(options[:post_url])
50
+      uri = URI options[:post_url]
51 51
       req = Net::HTTP::Post.new(uri.request_uri)
52 52
       req.form_data = data
53 53
       Net::HTTP.start(uri.hostname, uri.port, :use_ssl => uri.scheme == "https") { |http| http.request(req) }