Fix for serialize