mirror of https://github.com/zulip/zulip.git
zephyr: Fix typing for cred parameter.
This commit is contained in:
parent
0834514668
commit
99bd55917e
|
@ -13,6 +13,8 @@ import logging
|
|||
import subprocess
|
||||
import ujson
|
||||
|
||||
from typing import Optional
|
||||
|
||||
|
||||
# Hack for mit.edu users whose Kerberos usernames don't match what they zephyr
|
||||
# as. The key is for Kerberos and the value is for zephyr.
|
||||
|
@ -23,7 +25,7 @@ kerberos_alter_egos = {
|
|||
@authenticated_json_view
|
||||
@has_request_variables
|
||||
def webathena_kerberos_login(request: HttpRequest, user_profile: UserProfile,
|
||||
cred: str=REQ(default=None)) -> HttpResponse:
|
||||
cred: Optional[str]=REQ(default=None)) -> HttpResponse:
|
||||
global kerberos_alter_egos
|
||||
if cred is None:
|
||||
return json_error(_("Could not find Kerberos credential"))
|
||||
|
|
Loading…
Reference in New Issue