Ensure original errors are wrapped with "%w" instead of "%v"
This commit is contained in:
parent
3abde5f0c5
commit
fb5a35568c
12 changed files with 121 additions and 121 deletions
|
|
@ -21,7 +21,7 @@ func StartSSHServer(ctx context.Context, session *liveshare.Session, log logger)
|
|||
|
||||
sshServerStartResult, err := sshServer.StartRemoteServer(ctx)
|
||||
if err != nil {
|
||||
return 0, "", fmt.Errorf("error starting live share: %v", err)
|
||||
return 0, "", fmt.Errorf("error starting live share: %w", err)
|
||||
}
|
||||
|
||||
if !sshServerStartResult.Result {
|
||||
|
|
@ -30,7 +30,7 @@ func StartSSHServer(ctx context.Context, session *liveshare.Session, log logger)
|
|||
|
||||
portInt, err := strconv.Atoi(sshServerStartResult.ServerPort)
|
||||
if err != nil {
|
||||
return 0, "", fmt.Errorf("error parsing port: %v", err)
|
||||
return 0, "", fmt.Errorf("error parsing port: %w", err)
|
||||
}
|
||||
|
||||
return portInt, sshServerStartResult.User, nil
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue