deleteObject() method