George Notaras committed f774e72

Minor improvements of BaseThumbnailFieldFile

Comments (0)

Files changed (1)


 from thumbnail_works.images import ImageProcessor
 class BaseThumbnailFieldFile(ImageFieldFile):
     """A derived class of Django's ImageFieldFile for thumbnails.
         # Update the filesize cache
         self._size = len(thumbnail_content)
         self._committed = True
     def delete(self):
  = None
+        # Clear the thumbnail attribute on the source image file
         if hasattr(self.source, self.identifier):
             delattr(self.source, self.identifier)
         # Delete the filesize cache
         if hasattr(self, '_size'):
             del self._size
         self._committed = False
 class ThumbnailFieldFile(BaseThumbnailFieldFile, ImageProcessor):
-    pass
+    """An ImageFieldFile with image processing capabilities for thumbnails."""
 class BaseEnhancedImageFieldFile(ImageFieldFile):