mypy: Use Python 3 syntax for typing in views/tutorial.py.

This commit is contained in:
Xavier Cooney
2017-12-06 09:23:13 +00:00
committed by showell
parent 9bf0c96e9f
commit 63e793a8d1

View File

@@ -9,9 +9,8 @@ from zerver.models import UserProfile
@human_users_only
@has_request_variables
def set_tutorial_status(request, user_profile,
status=REQ(validator=check_string)):
# type: (HttpRequest, UserProfile, str) -> HttpResponse
def set_tutorial_status(request: HttpRequest, user_profile: UserProfile,
status: str=REQ(validator=check_string)) -> HttpResponse:
if status == 'started':
user_profile.tutorial_status = UserProfile.TUTORIAL_STARTED
elif status == 'finished':