Only display template if Page execution was successful

This commit is contained in:
2010-04-03 23:05:13 +01:00
parent 817b4b6388
commit 8e5e05fdea

View File

@@ -6,9 +6,10 @@ try {
$smarty = $main->smarty(); $smarty = $main->smarty();
$page = new HandBrakeCluster_Page($smarty, $main->request()); $page = new HandBrakeCluster_Page($smarty, $main->request());
$page->evaluate(); if ($page->evaluate()) {
$smarty->display('index.tpl'); $smarty->display('index.tpl');
}
} catch (HandBrakeCluster_Exception $e) { } catch (HandBrakeCluster_Exception $e) {
die("Uncaught Exception: " . $e->getMessage()); die("Uncaught Exception: " . $e->getMessage());
} }