Fixed serialization of HashMap