Added getitem and setitem functions to the User class