summaryrefslogtreecommitdiff
path: root/modules/gallery/helpers/gallery_task.php
diff options
context:
space:
mode:
authorTim Almdal <tnalmdal@shaw.ca>2009-09-02 13:44:37 -0700
committerTim Almdal <tnalmdal@shaw.ca>2009-09-02 13:44:37 -0700
commitaea34882b4121176a04d2eadba54aedccda5c08a (patch)
treea85c6e211b5803175d93e08724966be418ed4ce5 /modules/gallery/helpers/gallery_task.php
parentf2bbb2963a03c7f838772fa89facc0e38c3e4f4e (diff)
parent417c983491a7708a1d60e909caead239ef02eadd (diff)
Merge branch 'master' into talmdal
Diffstat (limited to 'modules/gallery/helpers/gallery_task.php')
-rw-r--r--modules/gallery/helpers/gallery_task.php11
1 files changed, 6 insertions, 5 deletions
diff --git a/modules/gallery/helpers/gallery_task.php b/modules/gallery/helpers/gallery_task.php
index c9557324..1b56ab97 100644
--- a/modules/gallery/helpers/gallery_task.php
+++ b/modules/gallery/helpers/gallery_task.php
@@ -60,14 +60,15 @@ class gallery_task_Core {
$item = ORM::factory("item", $row->id);
if ($item->loaded) {
- $success = graphics::generate($item);
- if (!$success) {
+ try {
+ graphics::generate($item);
$ignored[$item->id] = 1;
- $errors[] = t("Unable to rebuild images for '%title'",
- array("title" => html::purify($item->title)));
- } else {
$errors[] = t("Successfully rebuilt images for '%title'",
array("title" => html::purify($item->title)));
+ } catch (Exception $e) {
+ $errors[] = t("Unable to rebuild images for '%title'",
+ array("title" => html::purify($item->title)));
+ $errors[] = $e->__toString();
}
}