Fixes map serialization