Bugfix
[rock.divinelegy.git] / DataAccess / DataMapper / Helpers / VOMapsHelper.php
index 575d95e..61c7d4a 100644 (file)
@@ -53,7 +53,7 @@ class VOMapsHelper
         // If the table we already have contains the id of a row we need in\r
         // another table        \r
         //if(isset($row[$this->_tableName . '_id'])) {\r
-        if(array_key_exists($this->_tableName . '_id', $row)) { //this is a better choice as somtimes the array key is set, but is equal to null, and isset doesn't like that\r
+        if($row && array_key_exists($this->_tableName . '_id', $row)) { //this is a better choice as somtimes the array key is set, but is equal to null, and isset doesn't like that\r
             $join_id = $row[$this->_tableName . '_id'];\r
             $statement = $db->prepare(sprintf('SELECT * from %s WHERE id=%u',\r
                 $table,\r