Fixed bug with wrong value of item visibility - gallery, editItem