From eb3f2eff99c47a4bf71b7475720a26da835102ba Mon Sep 17 00:00:00 2001 From: hickert Date: Wed, 25 Jan 2006 09:06:07 +0000 Subject: [PATCH] Added some checks git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@2573 594d385d-05f5-0310-b6e9-bd551577e9d8 --- plugins/admin/systems/class_glpiAccount.inc | 2 -- plugins/admin/systems/class_glpiAttachmentPool.inc | 1 + 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/plugins/admin/systems/class_glpiAccount.inc b/plugins/admin/systems/class_glpiAccount.inc index a949632ea..71036a3ac 100644 --- a/plugins/admin/systems/class_glpiAccount.inc +++ b/plugins/admin/systems/class_glpiAccount.inc @@ -224,7 +224,6 @@ class glpiAccount extends plugin /* Remove Attachment fro this tab */ - $once = true; foreach($_POST as $name => $value){ if((preg_match("/^delAttachment_/",$name))&&($once)){ @@ -672,7 +671,6 @@ class glpiAccount extends plugin } $tmp = $this->handle->getComputerInformations($this->dn); $this->handle->addDevicesToComputer($this->usedDevices,$tmp[0]['ID']); - $this->handle->addAttachmentsToComputer($this->usedAttachments,$tmp[0]['ID']); } } diff --git a/plugins/admin/systems/class_glpiAttachmentPool.inc b/plugins/admin/systems/class_glpiAttachmentPool.inc index 896ed980b..25c39880c 100644 --- a/plugins/admin/systems/class_glpiAttachmentPool.inc +++ b/plugins/admin/systems/class_glpiAttachmentPool.inc @@ -113,6 +113,7 @@ class glpiAttachmentPool extends plugin }else{ $this->parent->handle->deleteAttachment($this->delAttach); + @unlink("/etc/gosa/glpi/".$this->filename); $attach = $this->parent->handle->getAttachments(); } } -- 2.30.2