Author: david
Date: Mon Jun 27 13:54:47 2011
New Revision: 9192

Log:
Test for `parent_id` to avoid PHP Notice.  Use conventional $item in foreach

Modified:
   trunk/lib/task/migrate/QubitMigrate107.class.php

Modified: trunk/lib/task/migrate/QubitMigrate107.class.php
==============================================================================
--- trunk/lib/task/migrate/QubitMigrate107.class.php    Mon Jun 27 13:50:48 
2011        (r9191)
+++ trunk/lib/task/migrate/QubitMigrate107.class.php    Mon Jun 27 13:54:47 
2011        (r9192)
@@ -929,12 +929,12 @@
     // Identify QubitInformationObject Root
     $rootKey = $this->getRowKey('QubitInformationObject', 'lft', '1');
 
-    foreach ($this->data['QubitInformationObject'] as $key => $value)
+    foreach ($this->data['QubitInformationObject'] as $key => $item)
     {
       // Assume all pre-existing information objects are published
       // Publication status is inherited by descendants so we only need to set 
it for
       // collection roots and orphans
-      if ($value['parent_id'] == $rootKey)
+      if (isset($item['parent_id']) && $item['parent_id'] == $rootKey)
       {
         $this->data['QubitStatus']['QubitStatus_publication_'.$key] = array(
           'object_id' => $key,

-- 
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