dev-cmd/bump-formula-pr: fix undefined method null error
Fix a regression from 8b1fcc7c5c18ec970c30e712ab283d7703694523. Only if `version.nil?` is `Version.detect` used, so we can only use `version.null?` after that. (Otherwise, it's a string.) ``` Error: undefined method `null?' for "X.Y.Z":String Please report this issue: https://docs.brew.sh/Troubleshooting /usr/local/Homebrew/Library/Homebrew/dev-cmd/bump-formula-pr.rb:440:in `check_new_version' /usr/local/Homebrew/Library/Homebrew/dev-cmd/bump-formula-pr.rb:131:in `bump_formula_pr' /usr/local/Homebrew/Library/Homebrew/brew.rb:110:in `<main>' ```
This commit is contained in:
parent
e76dce1aed
commit
3364e519b5
@ -435,9 +435,8 @@ module Homebrew
|
|||||||
specs = {}
|
specs = {}
|
||||||
specs[:tag] = tag if tag.present?
|
specs[:tag] = tag if tag.present?
|
||||||
version = Version.detect(url, **specs)
|
version = Version.detect(url, **specs)
|
||||||
end
|
|
||||||
|
|
||||||
return if version.null?
|
return if version.null?
|
||||||
|
end
|
||||||
|
|
||||||
check_throttle(formula, version)
|
check_throttle(formula, version)
|
||||||
check_closed_pull_requests(formula, tap_remote_repo, args: args, version: version)
|
check_closed_pull_requests(formula, tap_remote_repo, args: args, version: version)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user