fixes panic, still dk why result and err are nil. need to fix fucked up code

This commit is contained in:
Reed Allman
2017-06-11 02:49:42 -07:00
parent 345da3fcb3
commit bcdfa22248

View File

@@ -2,6 +2,7 @@ package runner
import (
"context"
"errors"
"fmt"
"io"
"sync"
@@ -96,6 +97,9 @@ func (rnr *Runner) RunTask(ctx context.Context, cfg *task.Config) (drivers.RunRe
}
resp := <-treq.Response
if resp.Result == nil && resp.Err == nil {
resp.Err = errors.New("error running task with unknown error")
}
return resp.Result, resp.Err
}