diff options
author | ewinslow <ewinslow@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2010-11-14 06:31:42 +0000 |
---|---|---|
committer | ewinslow <ewinslow@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2010-11-14 06:31:42 +0000 |
commit | f225bb716d270dcdbb313af5aec48083527d8a3e (patch) | |
tree | 1c48d609fcc0039dae539ec6bf24b59ccdb9321a /engine/classes/ElggEntity.php | |
parent | 95740405456f72d6d222b08a7b366e5559835ccf (diff) | |
download | elgg-f225bb716d270dcdbb313af5aec48083527d8a3e.tar.gz elgg-f225bb716d270dcdbb313af5aec48083527d8a3e.tar.bz2 |
Refs #2486: Added support for the 'recursive' parameter to ElggEntity::delete()
git-svn-id: http://code.elgg.org/elgg/trunk@7306 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'engine/classes/ElggEntity.php')
-rw-r--r-- | engine/classes/ElggEntity.php | 15 |
1 files changed, 4 insertions, 11 deletions
diff --git a/engine/classes/ElggEntity.php b/engine/classes/ElggEntity.php index 96d18142f..3df4b7a0c 100644 --- a/engine/classes/ElggEntity.php +++ b/engine/classes/ElggEntity.php @@ -996,10 +996,12 @@ abstract class ElggEntity extends ElggData implements /** * Delete this entity. * + * @param bool $recursive Whether to delete all the entities contained by this entity + * * @return bool */ - public function delete() { - return delete_entity($this->get('guid')); + public function delete($recursive = true) { + return delete_entity($this->get('guid'), $recursive); } /* @@ -1061,15 +1063,6 @@ abstract class ElggEntity extends ElggData implements return $this->get('geo:long'); } - /** - * Return the entity's location - * - * @return string - */ - public function getLocation() { - return $this->get('location'); - } - /* * NOTABLE INTERFACE */ |