Trying to get object  by class