We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5208788 commit 5a2cb15Copy full SHA for 5a2cb15
lib/contents.rb
@@ -38,6 +38,7 @@ def subpages_for filename
38
# (markdown) links of the form: [link text](link_page)
39
content.scan /\[.*?\]\((.*?)\)/ do |link, _|
40
next if (link =~ /^http/)
41
+ next if (link =~ %r(^//)) # protocol-less absolute links e.g. //google.com
42
next if (link =~ /(jpg|png)$/)
43
links.push(link) if !links.include? link
44
end
0 commit comments