From 6c90e65f6feeea8e1ba6fc692f790ce470e53059 Mon Sep 17 00:00:00 2001 From: Bevan Kay Date: Wed, 8 May 2024 14:55:43 +1000 Subject: [PATCH] livecheck/livecheck: fix passing an alternative url --- Library/Homebrew/livecheck/livecheck.rb | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/Library/Homebrew/livecheck/livecheck.rb b/Library/Homebrew/livecheck/livecheck.rb index 98811338a9..faec077d2d 100644 --- a/Library/Homebrew/livecheck/livecheck.rb +++ b/Library/Homebrew/livecheck/livecheck.rb @@ -762,11 +762,8 @@ module Homebrew # in the strategy's `#find_versions` method once we figure out why # `strategy.method(:find_versions).parameters` isn't working as # expected. - if strategy_name == "ExtractPlist" - strategy_args[:cask] = cask if cask.present? - else - strategy_args[:url] = url - end + strategy_args[:cask] = cask if strategy_name == "ExtractPlist" && cask.present? + strategy_args[:url] = url strategy_args.compact! strategy_data = strategy.find_versions(**strategy_args, &livecheck_strategy_block)