Skip to content

Commit

Permalink
Fixed error condition for checkDarwinArm64Constraint
Browse files Browse the repository at this point in the history
  • Loading branch information
Elia Bracci committed Dec 20, 2022
1 parent f204c68 commit 9fdfad8
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion lib/install.go
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,11 @@ func Install(tgversion string, usrBinPath string, mirrorURL string) string {

checkDarwinArm64Constraint, err := CheckDarwinArm64VersionConstraint(tgversion, goarch, goos)

if checkDarwinArm64Constraint && err == nil {
if err != nil {
log.Println(err)
}

if checkDarwinArm64Constraint {
fmt.Printf("%s satisfies Darwin arm64 constraints for tg version < 0.28.12. Switching arch to amd64 \n", tgversion)
goarch = "amd64"
}
Expand Down

0 comments on commit 9fdfad8

Please sign in to comment.