mirror of
https://github.com/Hopiu/django-imagekit.git
synced 2026-05-26 13:04:00 +00:00
Add module to sys.modules
This commit is contained in:
parent
2e4d435f4f
commit
bf1b45c943
1 changed files with 3 additions and 1 deletions
|
|
@ -23,7 +23,9 @@ class ProcessorImporter(object):
|
||||||
|
|
||||||
from django.utils.importlib import import_module
|
from django.utils.importlib import import_module
|
||||||
new_name = self.pattern.sub(r'pilkit.processors\1', name)
|
new_name = self.pattern.sub(r'pilkit.processors\1', name)
|
||||||
return import_module(new_name)
|
mod = import_module(new_name)
|
||||||
|
sys.modules[name] = mod
|
||||||
|
return mod
|
||||||
|
|
||||||
|
|
||||||
sys.meta_path.insert(0, ProcessorImporter())
|
sys.meta_path.insert(0, ProcessorImporter())
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue