Skip to content

Commit 382cc64

Browse files
committed
Fix 1.7 and new deps bugs
1 parent 7f2dcf5 commit 382cc64

File tree

2 files changed

+9
-7
lines changed

2 files changed

+9
-7
lines changed

cli_helpers.go

+8-6
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,9 @@ const errorMsg string = "Passphrase error occurred. Exiting..."
1616
// to ask the user for password or passphrase
1717
func PromptForHiddenInput(msg string) string {
1818
fmt.Printf(msg)
19-
return string(gopass.GetPasswd())
19+
pass, _ := gopass.GetPasswd()
20+
21+
return string(pass)
2022
}
2123

2224
func PromptForHiddenInputConfirm() string {
@@ -28,19 +30,19 @@ func PromptForHiddenInputConfirm() string {
2830
}
2931

3032
fmt.Printf(passPhraseMsg)
31-
inputPass := string(gopass.GetPasswd())
33+
inputPass, _ := gopass.GetPasswd()
3234

33-
if inputPass == "" {
35+
if string(inputPass) == "" {
3436
fmt.Printf("Empty passphrase not allowed\n\n")
3537
i++
3638
continue
3739
}
3840

3941
fmt.Printf(confirmMsg)
4042

41-
confirmPass := string(gopass.GetPasswd())
42-
if inputPass == confirmPass {
43-
return inputPass
43+
confirmPass, _ := gopass.GetPasswd()
44+
if string(inputPass) == string(confirmPass) {
45+
return string(inputPass)
4446
} else {
4547
fmt.Printf("Passphrases did not match. Please try again\n\n")
4648
}

remote/gist/storage.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ func (gs *GistStorage) Pull(remotePath, localPath string) (err error) {
7979
for _, g := range gists {
8080
for k, _ := range g.Files {
8181
if string(k) == remotePath {
82-
gist = &g
82+
gist = g
8383
break
8484
}
8585
}

0 commit comments

Comments
 (0)