Signed-off-by: Daniel Nephin <dnephin@docker.com>
| ... | ... |
@@ -147,7 +147,7 @@ func (c *client) Restore(ctx context.Context, id string, attachStdio StdioCallba |
| 147 | 147 |
rio, err = attachStdio(io) |
| 148 | 148 |
return rio, err |
| 149 | 149 |
}) |
| 150 |
- if err != nil && !strings.Contains(err.Error(), "no running task found") {
|
|
| 150 |
+ if err != nil && !errdefs.IsNotFound(errors.Cause(err)) {
|
|
| 151 | 151 |
return false, -1, err |
| 152 | 152 |
} |
| 153 | 153 |
|