diff options
author | brettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2009-06-29 20:02:45 +0000 |
---|---|---|
committer | brettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2009-06-29 20:02:45 +0000 |
commit | 55147bdc2632652ee5d06240650e7b1d85773141 (patch) | |
tree | 564699862f0db6389c4089b447d0c09e3af8e55d /engine/lib/annotations.php | |
parent | 0312ba291145b91da00f227fb739b69114fe63e0 (diff) | |
download | elgg-55147bdc2632652ee5d06240650e7b1d85773141.tar.gz elgg-55147bdc2632652ee5d06240650e7b1d85773141.tar.bz2 |
Closes #337: Added checking for metastrings in __get_annotations_calculate_x()
git-svn-id: https://code.elgg.org/elgg/trunk@3361 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'engine/lib/annotations.php')
-rw-r--r-- | engine/lib/annotations.php | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/engine/lib/annotations.php b/engine/lib/annotations.php index 309d475d7..79b2a9168 100644 --- a/engine/lib/annotations.php +++ b/engine/lib/annotations.php @@ -580,8 +580,10 @@ $entity_guid = (int)$entity_guid;
$entity_type = sanitise_string($entity_type);
$entity_subtype = get_subtype_id($entity_type, $entity_subtype);
- if ($name != '') $name = get_metastring_id($name); - if ($value != '') $value = get_metastring_id($value); + if ($name != '' AND !$name = get_metastring_id($name))
+ return 0; + if ($value != '' AND !$value = get_metastring_id($value))
+ return 0; $value_type = sanitise_string($value_type); $owner_guid = (int)$owner_guid;
|