Clear commands when done; add case for no input

This commit is contained in:
Logen Kain 2018-02-03 10:35:13 -07:00
parent 851dae2107
commit 97675ed9ec

View File

@ -208,8 +208,12 @@ func main() {
}
println("\nI don't know how to open a", command[1]+"!")
case "":
println("\n What do you want me to do? ")
break
default:
println("\nI don't know how to '", command[0], "'\n")
}
@ -237,5 +241,9 @@ func main() {
quit = true
}
}
/*Clear the commands in case the user just presses "enter"*/
command[0] = ""
command[1] = ""
}
}