Browse Source

Allow VerifyLinkService to accept backlinks with differing case (#18320)

closed-social-glitch-2
Sara Golemon 2 years ago
committed by GitHub
parent
commit
336c23336a
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      app/services/verify_link_service.rb

+ 1
- 1
app/services/verify_link_service.rb View File

@ -28,7 +28,7 @@ class VerifyLinkService < BaseService
links = Nokogiri::HTML(@body).xpath('//a[contains(concat(" ", normalize-space(@rel), " "), " me ")]|//link[contains(concat(" ", normalize-space(@rel), " "), " me ")]')
if links.any? { |link| link['href'] == @link_back }
if links.any? { |link| link['href'].downcase == @link_back.downcase }
true
elsif links.empty?
false

Loading…
Cancel
Save