From c7b3d070b65a84e3bfa9d8e3e6f52aac6552910f Mon Sep 17 00:00:00 2001 From: Sebastian Spaeth Date: Tue, 15 Jan 2013 15:03:00 +0100 Subject: Don't pass request into run_process_media People(tm) want to start run_process_media from the CLI and might not have a request object handy. So pass in the feed_url into run_process_media rather than the request object and allow the feed url to be empty (resulting in no PuSH notification at all then). Signed-off-by: Sebastian Spaeth --- mediagoblin/processing/task.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'mediagoblin/processing/task.py') diff --git a/mediagoblin/processing/task.py b/mediagoblin/processing/task.py index 2cdd5f1a..e9bbe084 100644 --- a/mediagoblin/processing/task.py +++ b/mediagoblin/processing/task.py @@ -94,7 +94,8 @@ class ProcessMedia(task.Task): entry.save() # Notify the PuSH servers as async task - handle_push_urls.subtask().delay(feed_url) + if mgg.app_config["push_urls"] and feed_url: + handle_push_urls.subtask().delay(feed_url) json_processing_callback(entry) except BaseProcessingFail as exc: -- cgit v1.2.3