mirror of
https://github.com/Hopiu/django-imagekit.git
synced 2026-03-16 21:30:23 +00:00
Use imagegenerators module, not imagespecs
This commit is contained in:
parent
0947c1403f
commit
92b11f8349
5 changed files with 9 additions and 9 deletions
|
|
@ -355,9 +355,9 @@ def get_singleton(class_path, desc):
|
|||
|
||||
def autodiscover():
|
||||
"""
|
||||
Auto-discover INSTALLED_APPS imagespecs.py modules and fail silently when
|
||||
not present. This forces an import on them to register any admin bits they
|
||||
may want.
|
||||
Auto-discover INSTALLED_APPS imagegenerators.py modules and fail silently
|
||||
when not present. This forces an import on them to register any admin bits
|
||||
they may want.
|
||||
|
||||
Copied from django.contrib.admin
|
||||
"""
|
||||
|
|
@ -370,12 +370,12 @@ def autodiscover():
|
|||
mod = import_module(app)
|
||||
# Attempt to import the app's admin module.
|
||||
try:
|
||||
import_module('%s.imagespecs' % app)
|
||||
import_module('%s.imagegenerators' % app)
|
||||
except:
|
||||
# Decide whether to bubble up this error. If the app just
|
||||
# doesn't have an imagespecs module, we can ignore the error
|
||||
# doesn't have an imagegenerators module, we can ignore the error
|
||||
# attempting to import it, otherwise we want it to bubble up.
|
||||
if module_has_submodule(mod, 'imagespecs'):
|
||||
if module_has_submodule(mod, 'imagegenerators'):
|
||||
raise
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ from django.core.files.uploadedfile import SimpleUploadedFile
|
|||
from imagekit import forms as ikforms
|
||||
from imagekit.processors import SmartCrop
|
||||
from nose.tools import eq_
|
||||
from . import imagespecs # noqa
|
||||
from . import imagegenerators # noqa
|
||||
from .models import ProcessedImageFieldModel, ImageModel
|
||||
from .utils import get_image_file
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
from django.template import TemplateSyntaxError
|
||||
from nose.tools import eq_, assert_not_in, raises, assert_not_equal
|
||||
from . import imagespecs # noqa
|
||||
from . import imagegenerators # noqa
|
||||
from .utils import render_tag, get_html_attrs
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
from django.template import TemplateSyntaxError
|
||||
from nose.tools import eq_, raises, assert_not_equal
|
||||
from . import imagespecs # noqa
|
||||
from . import imagegenerators # noqa
|
||||
from .utils import render_tag, get_html_attrs
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue