Author: jablko
Date: Tue Oct 12 18:10:38 2010
New Revision: 8076

Log:
Cosmetic change

Modified:
   
trunk/apps/qubit/modules/informationobject/actions/eventFormComponent.class.php

Modified: 
trunk/apps/qubit/modules/informationobject/actions/eventFormComponent.class.php
==============================================================================
--- 
trunk/apps/qubit/modules/informationobject/actions/eventFormComponent.class.php 
    Tue Oct 12 17:47:05 2010        (r8075)
+++ 
trunk/apps/qubit/modules/informationobject/actions/eventFormComponent.class.php 
    Tue Oct 12 18:10:38 2010        (r8076)
@@ -54,7 +54,7 @@
       }
 
       $event = new QubitEvent;
-      if (isset($item['id']) && !isset($this->request->sourceId))
+      if (!isset($this->request->sourceId) && isset($item['id']))
       {
         $params = $this->context->routing->parse(Qubit::pathInfo($item['id']));
         $event = $params['_sf_route']->resource;
@@ -113,14 +113,11 @@
       }
     }
 
-    if (false == isset($this->request->sourceId) && is_array($deleteEvents = 
$this->request->getParameter('deleteEvents')) && count($deleteEvents))
+    if (!isset($this->request->sourceId) && 
is_array($this->request->deleteEvents))
     {
-      foreach ($deleteEvents as $deleteId => $doDelete)
+      foreach ($this->request->deleteEvents as $item)
       {
-        if ('delete' == $doDelete && !is_null($event = 
QubitEvent::getById($deleteId)))
-        {
-          $event->delete();
-        }
+        QubitEvent::getById($deleteId)->delete();
       }
     }
   }

-- 
You received this message because you are subscribed to the Google Groups 
"Qubit Toolkit Commits" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/qubit-commits?hl=en.

Reply via email to