diff --git a/lib/vcr/library_hooks/webmock.rb b/lib/vcr/library_hooks/webmock.rb index 554f1de8..bfd1ed51 100644 --- a/lib/vcr/library_hooks/webmock.rb +++ b/lib/vcr/library_hooks/webmock.rb @@ -46,7 +46,7 @@ def request_headers_for(webmock_request) end def typed_request_for(webmock_request, remove = false) - if webmock_request.instance_variables.include?(:@__typed_vcr_request) + if webmock_request.instance_variables.find { |v| v.to_sym == :@__typed_vcr_request } meth = remove ? :remove_instance_variable : :instance_variable_get return webmock_request.send(meth, :@__typed_vcr_request) end