Fix serialize error