diff options
author | brettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2011-02-12 22:06:17 +0000 |
---|---|---|
committer | brettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2011-02-12 22:06:17 +0000 |
commit | cfde4ba516f7993043c467f6c63eaeab9390232b (patch) | |
tree | 77caf011381fe7ce68823d80baf8880a39476aac /engine/lib/metadata.php | |
parent | 34b7cd712e8c1a29f9e4a732514489a3c1505414 (diff) | |
download | elgg-cfde4ba516f7993043c467f6c63eaeab9390232b.tar.gz elgg-cfde4ba516f7993043c467f6c63eaeab9390232b.tar.bz2 |
Refs #650. Changed elgg_get_metadata_by_id() to elgg_get_metadata_from_id() to be consistent with other functions.
git-svn-id: http://code.elgg.org/elgg/trunk@8179 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'engine/lib/metadata.php')
-rw-r--r-- | engine/lib/metadata.php | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/engine/lib/metadata.php b/engine/lib/metadata.php index 7e4c1f68a..6724bcb70 100644 --- a/engine/lib/metadata.php +++ b/engine/lib/metadata.php @@ -31,7 +31,7 @@ function row_to_elggmetadata($row) { * * @return false|ElggMetadata */ -function elgg_get_metadata_by_id($id) { +function elgg_get_metadata_from_id($id) { $db_prefix = elgg_get_config('dbprefix'); $id = (int)$id; @@ -166,7 +166,7 @@ function create_metadata($entity_guid, $name, $value, $value_type, $owner_guid, $id = insert_data($query); if ($id !== false) { - $obj = elgg_get_metadata_by_id($id); + $obj = elgg_get_metadata_from_id($id); if (elgg_trigger_event('create', 'metadata', $obj)) { return $id; } else { @@ -195,7 +195,7 @@ function update_metadata($id, $name, $value, $value_type, $owner_guid, $access_i $id = (int)$id; - if (!$md = elgg_get_metadata_by_id($id)) { + if (!$md = elgg_get_metadata_from_id($id)) { return false; } if (!$md->canEdit()) { @@ -250,7 +250,7 @@ function update_metadata($id, $name, $value, $value_type, $owner_guid, $access_i $result = update_data($query); if ($result !== false) { - $obj = elgg_get_metadata_by_id($id); + $obj = elgg_get_metadata_from_id($id); if (elgg_trigger_event('update', 'metadata', $obj)) { return true; } else { @@ -301,7 +301,7 @@ function delete_metadata($id) { global $CONFIG; $id = (int)$id; - $metadata = elgg_get_metadata_by_id($id); + $metadata = elgg_get_metadata_from_id($id); if ($metadata) { // Tidy up if memcache is enabled. @@ -927,7 +927,7 @@ function metadata_array_to_values($array) { function get_metadata_url($id) { $id = (int)$id; - if ($extender = elgg_get_metadata_by_id($id)) { + if ($extender = elgg_get_metadata_from_id($id)) { return get_extender_url($extender); } return false; |