

def add_encoded(self, request, token):
    'Inject the ``encoded`` attribute to the token and return the token\n        '
    if odm:
        odm = request.app.odm()
        with odm.begin() as session:
            session.add(token)
            token.encoded = self.encode_token(request, token_id=token.id.hex, user=token.user, expiry=token.expiry)
    return token

dataset/ETHPy150Open quantmind/lux/lux/extensions/auth/backends.py AuthMixin.add_encoded/VarMisuse@17/47 `token`->`odm`