fix for GalleryHelper::get_images_from_main_language()