diff --git a/pkg/skaffold/sync/sync.go b/pkg/skaffold/sync/sync.go index 0f249b08c46..f04d377ad88 100644 --- a/pkg/skaffold/sync/sync.go +++ b/pkg/skaffold/sync/sync.go @@ -332,9 +332,12 @@ func Perform(ctx context.Context, image string, files syncMap, cmdFn func(contex } } + if err := errs.Wait(); err != nil { + return err + } + if numSynced == 0 { return errors.New("didn't sync any files") } - - return errs.Wait() + return nil }