def get_user_id(request):
"""Returns the record ID of the currently logged-in user. The user is derived
from the session cookie.
:param request: flask HTTP request object
:type request: `flash.Request`
:return:
the Invenio record ID od the currently logged-in user, or ``None`` if
this could not be detected
:rtype: str or NoneType
"""
return invenio_binding("get_user_id", request.cookies)
评论列表
文章目录