You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
11 lines
220 B
11 lines
220 B
# -*- coding: utf-8 -*-
|
|
"""Helper utilities and decorators."""
|
|
from conduit.user.models import User # noqa
|
|
|
|
|
|
def jwt_identity(payload):
|
|
return User.get_by_id(payload)
|
|
|
|
|
|
def identity_loader(user):
|
|
return user.id
|