mirror of https://github.com/zulip/zulip.git
mypy: Use Python 3 type syntax in zerver/views/custom_profile_fields.py.
This commit is contained in:
parent
613856c33b
commit
0fd0332a2c
|
@ -25,9 +25,9 @@ def list_realm_custom_profile_fields(request: HttpRequest, user_profile: UserPro
|
||||||
|
|
||||||
@require_realm_admin
|
@require_realm_admin
|
||||||
@has_request_variables
|
@has_request_variables
|
||||||
def create_realm_custom_profile_field(request, user_profile, name=REQ(),
|
def create_realm_custom_profile_field(request: HttpRequest,
|
||||||
field_type=REQ(validator=check_int)):
|
user_profile: UserProfile, name: Text=REQ(),
|
||||||
# type: (HttpRequest, UserProfile, Text, int) -> HttpResponse
|
field_type: int=REQ(validator=check_int)) -> HttpResponse:
|
||||||
if not name.strip():
|
if not name.strip():
|
||||||
return json_error(_("Name cannot be blank."))
|
return json_error(_("Name cannot be blank."))
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue