Gallery export fix