From f466def82dfac8f5ec73fc4726cbfc175fe19457 Mon Sep 17 00:00:00 2001 From: Corey Richardson Date: Fri, 15 Jun 2012 17:39:51 -0300 Subject: [PATCH] Better import of _imaging --- PIL/Image.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/PIL/Image.py b/PIL/Image.py index ec4d61ca7..e97623888 100644 --- a/PIL/Image.py +++ b/PIL/Image.py @@ -51,9 +51,7 @@ try: # the "open" function to identify files, but you cannot load # them. Note that other modules should not refer to _imaging # directly; import Image and use the Image.core variable instead. - import _imaging - core = _imaging - del _imaging + import _imaging as core except ImportError, v: core = _imaging_not_installed() if str(v)[:20] == "Module use of python" and warnings: