abstracted common code from parseClassesObject and parseObject, and moved it to a new function, parseObjectProperties