Ticket #1222: create_update.diff

File create_update.diff, 858 bytes (added by nick@…, 12 years ago)

Removes some of the magic still lurking in django.views.generic.create_update

  • create_update.py

    11from django.core.xheaders import populate_xheaders
    22from django.template import loader
    3 from django.core import formfields, meta
     3from django.core import formfields
     4from django.db.models import FileField
    45from django.views.auth.login import redirect_to_login
    56from django.template import RequestContext
    67from django.core.paginator import ObjectPaginator, InvalidPage
    2627        # If data was POSTed, we're trying to create a new object
    2728        new_data = request.POST.copy()
    29         if model._meta.has_field_type(meta.FileField):
     30        if model._meta.has_field_type(FileField):
    3031            new_data.update(request.FILES)
    3233        # Check for errors
Back to Top