-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
4 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
from django.http import HttpRequest, HttpResponse | ||
|
||
|
||
def index(request): | ||
def index(request: HttpRequest) -> HttpResponse: | ||
return HttpResponse("Hello, world. You're at the polls index.") | ||
|
||
def detail(request, question_id): | ||
def detail(request: HttpRequest, question_id: str) -> HttpResponse: | ||
return HttpResponse("You're looking at question %s." % question_id) | ||
|
||
def results(request, question_id): | ||
def results(request: HttpRequest, question_id: str) -> HttpResponse: | ||
response = "You're looking at the results of question %s." | ||
return HttpResponse(response % question_id) | ||
|
||
def vote(request, question_id): | ||
def vote(request: HttpRequest, question_id: str) -> HttpResponse: | ||
return HttpResponse("You're voting on question %s." % question_id) |