diff options
author | ewinslow <ewinslow@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2010-11-03 04:42:50 +0000 |
---|---|---|
committer | ewinslow <ewinslow@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2010-11-03 04:42:50 +0000 |
commit | 9cb00366281d1c9f85e4c7a0462802fd246ef0f5 (patch) | |
tree | 62f9a57345d24bc4ed83b327c4d67dec6d6ab8db /engine/classes | |
parent | 8cd8747bc2b7869c3eb861f11a13086f25b3c4a5 (diff) | |
download | elgg-9cb00366281d1c9f85e4c7a0462802fd246ef0f5.tar.gz elgg-9cb00366281d1c9f85e4c7a0462802fd246ef0f5.tar.bz2 |
Fixes #2050: Added subtype parameter to can_write_to_container functions and hooks
git-svn-id: http://code.elgg.org/elgg/trunk@7221 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'engine/classes')
-rw-r--r-- | engine/classes/ElggEntity.php | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/engine/classes/ElggEntity.php b/engine/classes/ElggEntity.php index ef38bee6b..66aca035e 100644 --- a/engine/classes/ElggEntity.php +++ b/engine/classes/ElggEntity.php @@ -651,14 +651,16 @@ abstract class ElggEntity extends ElggData implements } /** - * Can a user write to this entity's container. + * Can a user write to this entity * * @param int $user_guid The user. - * + * @param string $type The type of entity we're looking to write + * @param string $subtype The subtype of the entity we're looking to write + * * @return bool */ - public function canWriteToContainer($user_guid = 0) { - return can_write_to_container($user_guid, $this->getGUID()); + public function canWriteToContainer($user_guid = 0, $type = 'all', $subtype = 'all') { + return can_write_to_container($user_guid, $this->guid, $type, $subtype); } /** |