Skip to content

Commit

Permalink
fix: Remove debug print & restore console state after shell
Browse files Browse the repository at this point in the history
  • Loading branch information
erebe committed Dec 21, 2023
1 parent cc95a0e commit ae3825b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pkg/shell.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@ func ExecShell(req *ShellRequest) {
}()

currentConsole := console.Current()
defer currentConsole.Reset()

Check failure on line 40 in pkg/shell.go

View workflow job for this annotation

GitHub Actions / lint

Error return value of `currentConsole.Reset` is not checked (errcheck)

if err := currentConsole.SetRaw(); err != nil {
log.Fatal("error while setting up console", err)
}
Expand All @@ -62,7 +64,6 @@ func ExecShell(req *ShellRequest) {

func createWebsocketConn(req *ShellRequest) (*websocket.Conn, error) {
command, err := query.Values(req)
println("", command.Encode(), req.PodName)
if err != nil {
return nil, err
}
Expand Down

0 comments on commit ae3825b

Please sign in to comment.