app: make sure the image's metadata always has the right properties