mirror of https://github.com/docker/docs.git
Fixing ImageList Go code
Original: on line 18 we have `images, err := cli.ImageList(context.Background(), types.ImageListOptions{})` which gives us an error of: ``` # command-line-arguments ./main.go:12:2: ctx declared but not used ``` *Fix:* on line 18 we need to have `images, err := cli.ImageList(ctx, types.ImageListOptions{})`
This commit is contained in:
parent
9fdc494820
commit
6f38ea561b
|
@ -471,7 +471,7 @@ func main() {
|
||||||
panic(err)
|
panic(err)
|
||||||
}
|
}
|
||||||
|
|
||||||
images, err := cli.ImageList(context.Background(), types.ImageListOptions{})
|
images, err := cli.ImageList(ctx, types.ImageListOptions{})
|
||||||
if err != nil {
|
if err != nil {
|
||||||
panic(err)
|
panic(err)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue