mirror of
https://github.com/Hilbis/Hilbish
synced 2025-03-31 18:53:22 +00:00
fix: return if runner did not return table
This commit is contained in:
parent
60fd4c3b4c
commit
1d64a57e24
3
exec.go
3
exec.go
@ -175,6 +175,9 @@ func runLuaRunner(runr rt.Value, userInput string) (input string, exitCode uint8
|
||||
runnerRet := term.Get(0)
|
||||
if runner, ok = runnerRet.TryTable(); !ok {
|
||||
fmt.Fprintln(os.Stderr, "runner did not return a table")
|
||||
exitCode = 125
|
||||
input = userInput
|
||||
return
|
||||
}
|
||||
|
||||
if code, ok := runner.Get(rt.StringValue("exitCode")).TryInt(); ok {
|
||||
|
Loading…
x
Reference in New Issue
Block a user