]> gitweb.fluxo.info Git - lorea/elgg.git/commitdiff
Fixes #4111 guid is now an int
authorcash <cash.costello@gmail.com>
Sat, 19 Nov 2011 02:57:52 +0000 (21:57 -0500)
committercash <cash.costello@gmail.com>
Sat, 19 Nov 2011 02:57:52 +0000 (21:57 -0500)
engine/classes/ElggEntity.php
engine/classes/ElggGroup.php
engine/classes/ElggObject.php
engine/classes/ElggSite.php
engine/classes/ElggUser.php

index fdf2a80ea597ed34840aedbdc3339e461ec739b0..df87082fe084a62adf174445dd3e51d23b1f4ba3 100644 (file)
@@ -1335,6 +1335,9 @@ abstract class ElggEntity extends ElggData implements
                                $this->attributes['tables_loaded']++;
                        }
 
+                       // guid needs to be an int  http://trac.elgg.org/ticket/4111
+                       $this->attributes['guid'] = (int)$this->attributes['guid'];
+
                        // Cache object handle
                        if ($this->attributes['guid']) {
                                cache_entity($this);
index 5c16e978f78ad3f6a5535d751759a016790528b7..0190e5eacc31c39c744b0f36a7b0163990e91951 100644 (file)
@@ -349,6 +349,9 @@ class ElggGroup extends ElggEntity
                        $this->attributes[$key] = $value;
                }
 
+               // guid needs to be an int  http://trac.elgg.org/ticket/4111
+               $this->attributes['guid'] = (int)$this->attributes['guid'];
+
                return true;
        }
 
index caccfb0386a4671fb034de1a4dbfbb335648e9fa..0b8340697893d9371d00a914be6b3b314847a26f 100644 (file)
@@ -110,7 +110,7 @@ class ElggObject extends ElggEntity {
                $row = get_object_entity_as_row($guid);
                if (($row) && (!$this->isFullyLoaded())) {
                        // If $row isn't a cached copy then increment the counter
-                       $this->attributes['tables_loaded'] ++;
+                       $this->attributes['tables_loaded']++;
                }
 
                // Now put these into the attributes array as core values
@@ -119,6 +119,9 @@ class ElggObject extends ElggEntity {
                        $this->attributes[$key] = $value;
                }
 
+               // guid needs to be an int  http://trac.elgg.org/ticket/4111
+               $this->attributes['guid'] = (int)$this->attributes['guid'];
+
                return true;
        }
 
index 16b80b9d35a5e24e409226bbfd37dada7b604e0c..5c44d4076a93fc494fb25bfbdbdc3bf08542c2b0 100644 (file)
@@ -128,7 +128,7 @@ class ElggSite extends ElggEntity {
                $row = get_site_entity_as_row($guid);
                if (($row) && (!$this->isFullyLoaded())) {
                        // If $row isn't a cached copy then increment the counter
-                       $this->attributes['tables_loaded'] ++;
+                       $this->attributes['tables_loaded']++;
                }
 
                // Now put these into the attributes array as core values
@@ -137,6 +137,9 @@ class ElggSite extends ElggEntity {
                        $this->attributes[$key] = $value;
                }
 
+               // guid needs to be an int  http://trac.elgg.org/ticket/4111
+               $this->attributes['guid'] = (int)$this->attributes['guid'];
+
                return true;
        }
 
index 75ac008f6bfb90728fa76fa9ff243bed3fcfa77c..a1c7147a58ffe7f0ab25401fd79b12658c09a24c 100644 (file)
@@ -114,7 +114,7 @@ class ElggUser extends ElggEntity
                $row = get_user_entity_as_row($guid);
                if (($row) && (!$this->isFullyLoaded())) {
                        // If $row isn't a cached copy then increment the counter
-                       $this->attributes['tables_loaded'] ++;
+                       $this->attributes['tables_loaded']++;
                }
 
                // Now put these into the attributes array as core values
@@ -123,6 +123,9 @@ class ElggUser extends ElggEntity
                        $this->attributes[$key] = $value;
                }
 
+               // guid needs to be an int  http://trac.elgg.org/ticket/4111
+               $this->attributes['guid'] = (int)$this->attributes['guid'];
+
                return true;
        }