livecheck: fix parent reference handling

This commit is contained in:
Nanda H Krishna 2025-03-10 13:21:00 -04:00
parent 2f6db3757e
commit 1d35406905
No known key found for this signature in database
GPG Key ID: 067E5FCD58ADF3AA

View File

@ -895,9 +895,9 @@ module Homebrew
block_provided: livecheck_strategy_block.present?,
)
strategy = Strategy.from_symbol(livecheck_strategy) || strategies.first
next unless strategy
next if strategy.blank? && livecheck_reference != :parent
strategy_name = livecheck_strategy_names(strategy)
strategy_name = livecheck_strategy_names(strategy) if strategy.present?
if strategy.respond_to?(:preprocess_url)
url = strategy.preprocess_url(url)