Code

Opened 7 years ago

Closed 7 years ago

#4201 closed (fixed)

sessions example appears to be using pre-MR style

Reported by: Collin Grady <cgrady@…> Owned by: jacob
Component: Documentation Version: master
Severity: Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

Line 2 of the following example looks like pre-MR style for grabbing an object:

def login(request):
    m = members.get_object(username__exact=request.POST['username'])
    if m.password == request.POST['password']:
        request.session['member_id'] = m.id
        return HttpResponse("You're logged in.")
    else:
        return HttpResponse("Your username and password didn't match.")

Attachments (0)

Change History (1)

comment:1 Changed 7 years ago by adrian

  • Resolution set to fixed
  • Status changed from new to closed

(In [5140]) Fixed #4201 -- Fixed pre-MR style code example in docs/sessions.txt. Thanks, Collin Grady

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.