Digest::MD5.hexdigest replaced by WebSite.page_hash
This commit is contained in:
@@ -25,7 +25,7 @@ class WpTarget < WebSite
|
|||||||
response = Browser.get(@uri.merge('wp-content').to_s)
|
response = Browser.get(@uri.merge('wp-content').to_s)
|
||||||
|
|
||||||
if WpTarget.valid_response_codes.include?(response.code)
|
if WpTarget.valid_response_codes.include?(response.code)
|
||||||
hash = Digest::MD5.hexdigest(response.body)
|
hash = WebSite.page_hash(response)
|
||||||
return true if hash != error_404_hash and hash != homepage_hash
|
return true if hash != error_404_hash and hash != homepage_hash
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ class WpTarget < WebSite
|
|||||||
response = Browser.get(must_use_url)
|
response = Browser.get(must_use_url)
|
||||||
|
|
||||||
if response && WpTarget.valid_response_codes.include?(response.code)
|
if response && WpTarget.valid_response_codes.include?(response.code)
|
||||||
hash = Digest::MD5.hexdigest(response.body)
|
hash = WebSite.page_hash(response)
|
||||||
return true if hash != error_404_hash && hash != homepage_hash
|
return true if hash != error_404_hash && hash != homepage_hash
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user