From 8be98fb0127b22dd8c0a958317b661a540f1145a Mon Sep 17 00:00:00 2001 From: Michael Neves Date: Thu, 26 Jan 2012 20:38:21 +0100 Subject: Bootiso download fix --- application/modules/user/controllers/BootisoController.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'application/modules/user/controllers/BootisoController.php') diff --git a/application/modules/user/controllers/BootisoController.php b/application/modules/user/controllers/BootisoController.php index bd6793c..79812b4 100644 --- a/application/modules/user/controllers/BootisoController.php +++ b/application/modules/user/controllers/BootisoController.php @@ -96,7 +96,8 @@ class user_BootisoController extends Zend_Controller_Action { $bootiso->setGroupID("[".$bootiso->getGroupID()."] ".$groupMapper->find($bootiso->getGroupID())->getTitle()); $bootiso->setPreBootTypeID($preboottypeMapper->find($bootiso->getPreBootTypeID())->getName()); $bootiso->setCreated(date(Zend_Registry::get('dateformat'), $bootiso->getCreated())); - if(count($prebootMapper->findBy(array('serialnumber' => $bootiso->getSerialnumber(), 'preboottypeID' => $bootiso->getPreboottypeID()))) != 0){ + $preboots = $prebootMapper->findBy(array('serialnumber' => $bootiso->getSerialnumber(), 'preboottypeID' => $bootiso->getPreboottypeID())); + if(count($preboots) != 0){ $this->view->download[$bootiso->getID()] = true; } if($bootiso->getExpires() == "") { -- cgit v1.2.3-55-g7522