From 3988c9d66db47ded3df012bb2e8d8bf04f2f4fd4 Mon Sep 17 00:00:00 2001 From: Rodney Ewing Date: Tue, 6 Aug 2013 09:17:37 -0700 Subject: [PATCH] forgot to change to a class from a function after the refactor --- mediagoblin/media_types/image/__init__.py | 4 ++-- mediagoblin/media_types/image/processing.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/mediagoblin/media_types/image/__init__.py b/mediagoblin/media_types/image/__init__.py index de7de3ac..e2b00e50 100644 --- a/mediagoblin/media_types/image/__init__.py +++ b/mediagoblin/media_types/image/__init__.py @@ -19,7 +19,7 @@ import logging from mediagoblin.db.models import MediaEntry from mediagoblin.media_types import MediaManagerBase -from mediagoblin.media_types.image.processing import process_image, \ +from mediagoblin.media_types.image.processing import ProcessImage, \ sniff_handler from mediagoblin.submit.lib import run_process_media from mediagoblin.tools import pluginapi @@ -38,7 +38,7 @@ def setup_plugin(): class ImageMediaManager(MediaManagerBase): human_readable = "Image" - processor = staticmethod(process_image) + processor = ProcessImage display_template = "mediagoblin/media_displays/image.html" default_thumb = "images/media_thumbs/image.png" diff --git a/mediagoblin/media_types/image/processing.py b/mediagoblin/media_types/image/processing.py index 665a2931..8126ea2d 100644 --- a/mediagoblin/media_types/image/processing.py +++ b/mediagoblin/media_types/image/processing.py @@ -124,7 +124,7 @@ def sniff_handler(media_file, **kw): return None -def process_image(proc_state, reprocess_info=None): +class ProcessImage(object): """Code to process an image. Will be run by celery. A Workbench() represents a local tempory dir. It is automatically -- 2.25.1