bugfix: rescue url error in url target helper

This commit is contained in:
Christoph Hartmann 2016-02-02 14:02:55 +01:00
parent 6c1b9fff9d
commit 2cb3d6f90f

View file

@ -13,6 +13,8 @@ module Inspec::Targets
uri = URI.parse(target)
return false if uri.nil? or uri.scheme.nil?
%{ http https }.include? uri.scheme
rescue URI::Error => e
false
end
def resolve(target, opts = {})