Fix a deprecation warning
This commit is contained in:
@@ -6,7 +6,7 @@ from fnmatch import fnmatch
|
||||
from optparse import make_option
|
||||
|
||||
import django
|
||||
from django.core.management.base import NoArgsCommand, CommandError
|
||||
from django.core.management.base import BaseCommand, CommandError
|
||||
import django.template
|
||||
from django.template import Context
|
||||
from django.utils import six
|
||||
@@ -40,9 +40,9 @@ else:
|
||||
from StringIO import StringIO
|
||||
|
||||
|
||||
class Command(NoArgsCommand):
|
||||
class Command(BaseCommand):
|
||||
help = "Compress content outside of the request/response cycle"
|
||||
option_list = NoArgsCommand.option_list + (
|
||||
option_list = BaseCommand.option_list + (
|
||||
make_option('--extension', '-e', action='append', dest='extensions',
|
||||
help='The file extension(s) to examine (default: ".html", '
|
||||
'separate multiple extensions with commas, or use -e '
|
||||
|
||||
@@ -2,15 +2,15 @@ import fnmatch
|
||||
import os
|
||||
from optparse import make_option
|
||||
|
||||
from django.core.management.base import NoArgsCommand, CommandError
|
||||
from django.core.management.base import BaseCommand, CommandError
|
||||
|
||||
from compressor.conf import settings
|
||||
from compressor.cache import cache, get_mtime, get_mtime_cachekey
|
||||
|
||||
|
||||
class Command(NoArgsCommand):
|
||||
class Command(BaseCommand):
|
||||
help = "Add or remove all mtime values from the cache"
|
||||
option_list = NoArgsCommand.option_list + (
|
||||
option_list = BaseCommand.option_list + (
|
||||
make_option('-i', '--ignore', action='append', default=[],
|
||||
dest='ignore_patterns', metavar='PATTERN',
|
||||
help="Ignore files or directories matching this glob-style "
|
||||
|
||||
Reference in New Issue
Block a user