Use the image meta data in `Controller::addEnclosuresToTemplate()` (see #6746)