Skip to content
This repository
Browse code

Merge pull request #151 from joevandyk/master

Fix "warning: instance variable @query_params not initialized" warning
  • Loading branch information...
commit 2675b10737b6dbdd0232398ec3bb7e642a709b4e 2 parents ad9ea7f + e459569
Bartosz Blimke authored February 04, 2012

Showing 1 changed file with 4 additions and 0 deletions. Show diff stats Hide diff stats

  1. 4  lib/webmock/request_pattern.rb
4  lib/webmock/request_pattern.rb
@@ -79,6 +79,10 @@ def initialize(pattern)
79 79
   end
80 80
 
81 81
   class URIRegexpPattern  < URIPattern
  82
+    def initialize *args, &block
  83
+      @query_params = nil
  84
+      super
  85
+    end
82 86
 
83 87
     def matches?(uri)
84 88
       WebMock::Util::URI.variations_of_uri_as_strings(uri).any? { |u| u.match(@pattern) } &&

0 notes on commit 2675b10

Please sign in to comment.
Something went wrong with that request. Please try again.