fix ser/deser