diff options
author | marcus <marcus@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2009-04-22 15:49:24 +0000 |
---|---|---|
committer | marcus <marcus@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2009-04-22 15:49:24 +0000 |
commit | 9d862819cf8f1d9f14a4f5465ca84579b05fb959 (patch) | |
tree | b7c489f15e8d544163ca543f02e02f84b8516b6e /engine/lib/metadata.php | |
parent | 8b5fd806d6871aaeb179376328a8af215ed44f88 (diff) | |
download | elgg-9d862819cf8f1d9f14a4f5465ca84579b05fb959.tar.gz elgg-9d862819cf8f1d9f14a4f5465ca84579b05fb959.tar.bz2 |
Deleting correct data + using correct tables
git-svn-id: https://code.elgg.org/elgg/trunk@3228 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'engine/lib/metadata.php')
-rw-r--r-- | engine/lib/metadata.php | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/engine/lib/metadata.php b/engine/lib/metadata.php index 57987107c..ca127c386 100644 --- a/engine/lib/metadata.php +++ b/engine/lib/metadata.php @@ -739,6 +739,8 @@ */ function clear_metadata_by_owner($owner_guid) { + global $CONFIG; + $owner_guid = (int)$owner_guid; $metas = get_data("SELECT id from {$CONFIG->dbprefix}metadata WHERE owner_guid=$owner_guid"); @@ -746,7 +748,7 @@ foreach ($metas as $id) { - if (delete_metadata($id)) // Is this the best way? + if (delete_metadata($id->id)) // Is this the best way? $deleted++; } |