diff options
Diffstat (limited to 'lib/banzai/filter/asset_proxy_filter.rb')
-rw-r--r-- | lib/banzai/filter/asset_proxy_filter.rb | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/banzai/filter/asset_proxy_filter.rb b/lib/banzai/filter/asset_proxy_filter.rb index 00ffdd3d809..512c55381ec 100644 --- a/lib/banzai/filter/asset_proxy_filter.rb +++ b/lib/banzai/filter/asset_proxy_filter.rb @@ -22,13 +22,13 @@ module Banzai begin uri = URI.parse(original_src) + + next if uri.host.nil? && !original_src.start_with?('///') + next if asset_host_allowed?(uri.host) rescue StandardError - next + # Ignored end - next if uri.host.nil? && !original_src.start_with?('///') - next if asset_host_allowed?(uri.host) - element['src'] = asset_proxy_url(original_src) element['data-canonical-src'] = original_src end |