LPS-42302 Apply same fix as in image_gallery