From 07a6c7e45eb742081cb0587352e6670dad07bce0 Mon Sep 17 00:00:00 2001 From: ben Date: Thu, 22 May 2008 14:00:22 +0000 Subject: Rearranging events: stage 1 git-svn-id: https://code.elgg.org/elgg/trunk@680 36083f99-b078-4883-b0ff-0f9b5a30f544 --- engine/lib/entities.php | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'engine/lib/entities.php') diff --git a/engine/lib/entities.php b/engine/lib/entities.php index 0cbd538a6..17b6ff7f3 100644 --- a/engine/lib/entities.php +++ b/engine/lib/entities.php @@ -767,12 +767,8 @@ // Erased by Ben: sometimes we need unauthenticated users to create things! (eg users on registration) // if ($owner_guid==0) throw new InvalidParameterException("owner_guid must not be 0"); - - if ($result = insert_data("INSERT into {$CONFIG->dbprefix}entities (type, subtype, owner_guid, site_guid, access_id, time_created, time_updated) values ('$type',$subtype, $owner_guid, $site_guid, $access_id, $time, $time)")) { - $entity = get_entity($result); - trigger_event('create',$entity->type,$entity); - } - return $result; + + return insert_data("INSERT into {$CONFIG->dbprefix}entities (type, subtype, owner_guid, site_guid, access_id, time_created, time_updated) values ('$type',$subtype, $owner_guid, $site_guid, $access_id, $time, $time)"); } /** -- cgit v1.2.3