Permalink
Browse files

deprecate attached()

  • Loading branch information...
1 parent 8acdb12 commit 94f19ef4b8a3f71d4d42201896c7d227f2f2bd6c @dereuromark dereuromark committed Nov 16, 2012
Showing with 13 additions and 0 deletions.
  1. +13 −0 lib/Cake/Utility/ObjectCollection.php
@@ -271,6 +271,19 @@ public function enabled($name = null) {
* returns an array of currently-attached behaviors
* @return mixed If $name is specified, returns the boolean status of the corresponding behavior.
* Otherwise, returns an array of all attached behaviors.
+ * @deprecated Use loaded instead.
+ */
+ public function attached($name = null) {
+ return $this->loaded($name);
+ }
+
+/**
+ * Gets the list of loaded objects, or, whether the given object is loaded
+ *
+ * @param string $name Optional. The name of the behavior to check the status of. If omitted,
+ * returns an array of currently-loaded behaviors
+ * @return mixed If $name is specified, returns the boolean status of the corresponding behavior.
+ * Otherwise, returns an array of all loaded behaviors.
*/
public function loaded($name = null) {
if (!empty($name)) {

0 comments on commit 94f19ef

Please sign in to comment.