mirror of
https://github.com/rwinkhart/libmutton.git
synced 2026-10-26 22:09:56 -04:00
Fix continuous TOTP copy
This commit is contained in:
1 parent
75ad2afcfb
commit
14dda0b091
1 file changed
+2
-1
@@ -46,9 +46,10 @@ func CopyArgument(targetLocation string, field int) error {
|
||||
errorChan := make(chan error)
|
||||
go TOTPCopier(decSlice[2], field, errorChan, nil) // "done" is not needed because the process runs until the program is killed
|
||||
err = <-errorChan
|
||||
if err != nil { // block until first successful copy
|
||||
if err != nil { // handle error from first copy
|
||||
return errors.New("error encountered in TOTP refresh process: " + err.Error())
|
||||
}
|
||||
select {} // block indefinitely
|
||||
} else { // other
|
||||
copySubject = decSlice[realField]
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user