Did I find the right examples for you? yes no

All Samples(3)  |  Call(3)  |  Derive(0)  |  Import(0)

src/t/u/tuskar-HEAD/tuskar/common/context.py   tuskar(Download)
        self.is_admin = is_admin
        if self.is_admin is None:
            self.is_admin = policy.check_is_admin(self)
        if overwrite or not hasattr(local.store, 'context'):
            self.update_store()

src/t/u/tuskar-HEAD/tuskar/api/acl.py   tuskar(Download)
    def before(self, state):
        headers = state.request.headers
        if not policy.check_is_admin(headers.get('X-Roles', "").split(",")):
            raise exc.HTTPUnauthorized()
 

src/t/u/tuskar-0.4.1/tuskar/common/context.py   tuskar(Download)
        self.is_admin = is_admin
        if self.is_admin is None:
            self.is_admin = policy.check_is_admin(self)
        if overwrite or not hasattr(local.store, 'context'):
            self.update_store()