From 23f3285f314b3d6a57b6a1eacd9baa118fa6ba04 Mon Sep 17 00:00:00 2001 From: hickert Date: Thu, 15 Feb 2007 10:58:49 +0000 Subject: [PATCH] Create faiPackageList: -Avoid several undefined index errors, if there is no server available that supports the selected release git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@5720 594d385d-05f5-0310-b6e9-bd551577e9d8 --- plugins/admin/fai/class_faiPackage.inc | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/plugins/admin/fai/class_faiPackage.inc b/plugins/admin/fai/class_faiPackage.inc index edadc11a0..0635c85e4 100644 --- a/plugins/admin/fai/class_faiPackage.inc +++ b/plugins/admin/fai/class_faiPackage.inc @@ -195,8 +195,14 @@ class faiPackage extends plugin /* Assemble sections */ $repos= $this->getServerInfos(); - $this->FAIdebianSection= $repos[$this->FAIdebianRelease]; - $this->FAIdebianSection= array_unique($this->FAIdebianSection); + + if(isset($repos[$this->FAIdebianRelease])){ + $this->FAIdebianSection= $repos[$this->FAIdebianRelease]; + $this->FAIdebianSection= array_unique($this->FAIdebianSection); + }else{ + $this->FAIdebianSection = array(); + print_red(sprintf(_("No repository server found that provide this release '%s'."), $this->FAIdebianRelease)); + } /* Assign Repository settings*/ $this->is_account = true; -- 2.30.2