Преглед изворни кода

Drop newline when reading input in REPL

Alois Mahdal пре 3 дана
родитељ
комит
a97c81dc3a
1 измењених фајлова са 1 додато и 1 уклоњено
  1. 1
    1
      app/main.go

+ 1
- 1
app/main.go Прегледај датотеку

@@ -15,7 +15,7 @@ func getInput(ctx *core.Context) (string, error) {
15 15
 	if err != nil {
16 16
 		return "", err
17 17
 	}
18
-	return input, nil
18
+	return input[:len(input)-1], nil
19 19
 }
20 20
 
21 21
 func repl(ctx *core.Context) {