From 35e46d8d6ba157cc0ca3d6a72f542ffe136786c5 Mon Sep 17 00:00:00 2001 From: baude Date: Fri, 5 Apr 2019 10:10:11 -0500 Subject: add image rmi event when deleting a commited image, the path for deletion has an early exit and the image remove event was not being triggered. Signed-off-by: baude --- libpod/image/image.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'libpod/image/image.go') diff --git a/libpod/image/image.go b/libpod/image/image.go index cc056b816..757d034a2 100644 --- a/libpod/image/image.go +++ b/libpod/image/image.go @@ -361,6 +361,7 @@ func (i *Image) Remove(force bool) error { if _, err := i.imageruntime.store.DeleteImage(i.ID(), true); err != nil { return err } + i.newImageEvent(events.Remove) for parent != nil { nextParent, err := parent.GetParent() if err != nil { @@ -383,7 +384,6 @@ func (i *Image) Remove(force bool) error { } parent = nextParent } - defer i.newImageEvent(events.Remove) return nil } -- cgit v1.2.3-54-g00ecf