lib/spidr/agent/sanitizers.rb in spidr-0.6.0 vs lib/spidr/agent/sanitizers.rb in spidr-0.6.1
- old
+ new
@@ -19,10 +19,10 @@
# The new sanitized URL.
#
# @since 0.2.2
#
def sanitize_url(url)
- url = URI(url.to_s) unless url.kind_of?(URI)
+ url = URI(url)
url.fragment = nil if @strip_fragments
url.query = nil if @strip_query
return url