mirror of
https://github.com/docker/docs.git
synced 2026-03-27 14:28:47 +07:00
relative_links_filter: do not replace html link
Do not manipulate links that don't point to a .md file. Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
@@ -97,12 +97,16 @@ module Jekyll
|
||||
nil
|
||||
end
|
||||
|
||||
def mdtarget?(string)
|
||||
string&.include?(".md")
|
||||
end
|
||||
|
||||
def fragment?(string)
|
||||
string&.start_with?("#")
|
||||
end
|
||||
|
||||
def replaceable_link?(string)
|
||||
!fragment?(string) && !absolute_url?(string)
|
||||
mdtarget?(string) && !fragment?(string) && !absolute_url?(string)
|
||||
end
|
||||
|
||||
def global_entry_filter
|
||||
|
||||
Reference in New Issue
Block a user