Ticket #2429: tutorial4.diff
File tutorial4.diff, 566 bytes (added by , 18 years ago) |
---|
-
tutorial04.txt
54 54 p = get_object_or_404(Poll, pk=poll_id) 55 55 try: 56 56 selected_choice = p.choice_set.get(pk=request.POST['choice']) 57 except (KeyError, Choice.DoesNotExist):57 except (KeyError, p.DoesNotExist): 58 58 # Redisplay the poll voting form. 59 59 return render_to_response('polls/detail.html', { 60 60 'poll': p,