Fixing some enum serialisation