We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7d9c293 commit ccc0291Copy full SHA for ccc0291
1 file changed
internal/command/update.go
@@ -159,7 +159,7 @@ func replaceExecutable(url string) error {
159
}
160
defer os.Remove(archive)
161
162
- binary, err := extractBinary(archive)
+ binary, err := extractBinary(archive, url)
163
if err != nil {
164
return err
165
@@ -204,8 +204,8 @@ func downloadFile(url string) (string, error) {
204
return tmp.Name(), nil
205
206
207
-func extractBinary(archive string) ([]byte, error) {
208
- if strings.HasSuffix(archive, ".zip") {
+func extractBinary(archive string, url string) ([]byte, error) {
+ if strings.HasSuffix(url, ".zip") {
209
return extractFromZip(archive)
210
211
return extractFromTarGz(archive)
0 commit comments