Make User class Serializable.