Fixed media manager not uploading the images (see #604)