From 5af0adf1ccc660d4c3d0fb0f107d83a511b7d989 Mon Sep 17 00:00:00 2001 From: ben Date: Wed, 4 Mar 2009 18:29:36 +0000 Subject: Access fix git-svn-id: https://code.elgg.org/elgg/trunk@3085 36083f99-b078-4883-b0ff-0f9b5a30f544 --- engine/lib/entities.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/engine/lib/entities.php b/engine/lib/entities.php index 38bfd13dc..93f12b057 100644 --- a/engine/lib/entities.php +++ b/engine/lib/entities.php @@ -1285,6 +1285,9 @@ if (trigger_elgg_event('update',$entity->type,$entity)) { $ret = update_data("UPDATE {$CONFIG->dbprefix}entities set owner_guid='$owner_guid', access_id='$access_id', container_guid='$container_guid', time_updated='$time' WHERE guid=$guid"); + if ($entity instanceof ElggObject) + update_river_access_by_object($guid,$access_id); + // If memcache is available then delete this entry from the cache static $newentity_cache; if ((!$newentity_cache) && (is_memcache_available())) @@ -1294,9 +1297,6 @@ // Handle cases where there was no error BUT no rows were updated! if ($ret===false) return false; - - if ($entity instanceof ElggObject) - update_river_access_by_object($entity->guid,$entity->access_id); return true; } -- cgit v1.2.3