change flags provided in serialization to make them more consistent