#9075: Missing destination.close()
---------------------------+------------------------------------------------
Reporter: bmsleight | Owner: nobody
Status: new | Milestone:
Component: Documentation | Version: 1.0
Keywords: | Stage: Unreviewed
Has_patch: 0 |
---------------------------+------------------------------------------------
In page http://docs.djangoproject.com/en/dev/topics/http/file-uploads/
{{{
def handle_uploaded_file(f):
destination = open('some/file/name.txt', 'wb+')
for chunk in f.chunks():
destination.write(chunk)
}}}
IMHO should read:-
{{{
def handle_uploaded_file(f):
destination = open('some/file/name.txt', 'wb+')
for chunk in f.chunks():
destination.write(chunk)
destination.close()
}}}
Regards,
Brendan
--
Ticket URL: <http://code.djangoproject.com/ticket/9075>
Django <http://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---