Fix serialization of crid