Skip to:
Content

BuddyPress.org

Changeset 6666 for trunk/bp-loader.php


Ignore:
Timestamp:
12/25/2012 09:51:39 AM (13 years ago)
Author:
johnjamesjacoby
Message:

Add magic call and unset methods to main BuddyPress class.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bp-loader.php

    r6637 r6666  
    189189     */
    190190    public function __set( $key, $value ) { $this->data[$key] = $value; }
     191
     192    /**
     193     * Magic method for unsetting BuddyPress variables
     194     *
     195     * @since BuddyPress (1.7)
     196     */
     197    public function __unset( $key ) { if ( isset( $this->data[$key] ) ) unset( $this->data[$key] ); }
     198
     199    /**
     200     * Magic method to prevent notices and errors from invalid method calls
     201     *
     202     * @since BuddyPress (1.7)
     203     */
     204    public function __call( $name = '', $args = array() ) { unset( $name, $args ); return null; }
    191205
    192206    /** Private Methods *******************************************************/
Note: See TracChangeset for help on using the changeset viewer.