Ticket #5848: 5848.core.management.commands.flush.diff

File 5848.core.management.commands.flush.diff, 1.0 KB (added by Pete Crosier, 17 years ago)

Make flush use set for created_models

  • django/core/management/commands/flush.py

     
    22from django.core.management.color import no_style
    33from optparse import make_option
    44
     5try:
     6    set
     7except NameError:
     8    from sets import Set as set   # Python 2.3 fallback
     9
    510class Command(NoArgsCommand):
    611    option_list = NoArgsCommand.option_list + (
    712        make_option('--verbosity', action='store', dest='verbosity', default='1',
     
    6166            # Emit the post sync signal. This allows individual
    6267            # applications to respond as if the database had been
    6368            # sync'd from scratch.
    64             emit_post_sync_signal(models.get_models(), verbosity, interactive)
     69            emit_post_sync_signal(set(models.get_models()), verbosity, interactive)
    6570
    6671            # Reinstall the initial_data fixture.
    6772            from django.core.management import call_command
Back to Top