diff --git a/job.go b/job.go index 0d15cee1167507ab7737e53fa7812434d6b9ebca..262cdc5199f2af00eb91ff817fe2987e0fee54dc 100644 --- a/job.go +++ b/job.go @@ -255,7 +255,7 @@ func (j *Job[T]) Execute(ctx context.Context) (RunGenericResult, error) { newLog.IsSuccessful = true newLog.ExitCode = 0 } else { - switch v := any(r.Data).(type) { + switch v := any(&r.Data).(type) { case GetResultAndError: newLog.ErrorMsg, newLog.ExitCode = v.GetError() } @@ -276,7 +276,7 @@ func (j *Job[T]) Execute(ctx context.Context) (RunGenericResult, error) { newLog.EndTime = time.Now() - switch v := any(r.Data).(type) { + switch v := any(&r.Data).(type) { case GetResultAndError: newLog.Result = v.GetResult() }