Skip to content

Commit

Permalink
Apply review suggestion from @nilsding
Browse files Browse the repository at this point in the history
Co-authored-by: Georg Gadinger <[email protected]>
  • Loading branch information
pixeldesu and nilsding committed Jan 2, 2022
1 parent 48c31eb commit fab007b
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions app/services/shared_markers.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@ module SharedMarkers

def autolink(link, _link_type)
href = if ALLOWED_HOSTS_IN_MARKDOWN.include?(URI(link).host)
link
else
linkfilter_path(url: link)
end
link
else
linkfilter_path(url: link)
end

content_tag(:a, link, href: href, target: "_blank", rel: "nofollow")
rescue
link
Expand Down

0 comments on commit fab007b

Please sign in to comment.