def obj_get(self, bundle, **kwargs):
        domain = kwargs['domain']
        pk = kwargs['pk']
        try:
            user = self.Meta.object_class.get_by_user_id(pk, domain)
        except __HOLE__:
            user = None
        return user
dataset/ETHPy150Open dimagi/commcare-hq/corehq/apps/api/resources/v0_1.py/UserResource.obj_get