webhooks/dialogflow: Remove default value for email parameter.

The webhook view used a default value for the email, which gave
non-informative errors when the webhook is incorrectly configured without
the email parameter.
This commit is contained in:
Puneeth Chaganti 2020-04-17 17:20:18 +05:30 committed by Tim Abbott
parent 97792466ec
commit 36623cddfd

View File

@ -14,7 +14,7 @@ from zerver.models import UserProfile, get_user_profile_by_email
@has_request_variables
def api_dialogflow_webhook(request: HttpRequest, user_profile: UserProfile,
payload: Dict[str, Any]=REQ(argument_type='body'),
email: str=REQ(default='foo')) -> HttpResponse:
email: str=REQ()) -> HttpResponse:
status = payload["status"]["code"]
if status == 200: