public function deleteAttribute($attributes, $sync = true)
    {
        // If we've been given a string, we'll assume we're removing a
        // single attribute. Otherwise, we'll assume it's
        // an array of attributes to remove.
        $attributes = is_string($attributes) ? [$attributes => []] : $attributes;

        if (
            $this->exists &&
            $this->query->getConnection()->modDelete($this->getDn(), $attributes)
        ) {
            if ($sync) {
                $this->syncRaw();
            }

            return true;
        }

        return false;
    }
public function deleteAttribute($attributes, $sync = true)
    {
        // If we've been given a string, we'll assume we're removing a
        // single attribute. Otherwise, we'll assume it's
        // an array of attributes to remove.
        $attributes = is_string($attributes) ? [$attributes => []] : $attributes;

        if (
            $this->exists &&
            $this->query->getConnection()->modDelete($this->getDn(), $attributes)
        ) {
            if ($sync) {
                $this->syncRaw();
            }

            return true;
        }

        return false;
    }
public function deleteAttribute ( $ attributes , $ sync = true ) { // If we've been given a string, we'll assume we're removing a // single attribute. Otherwise, we'll assume it's // an array of attributes to remove. $ attributes = is_string ( $ attributes ) ? [ $ attributes => [ ] ] : $ attributes ; if ( $ this -> exists && $ this -> query -> getConnection ( ) -> modDelete ( $ this -> getDn ( ) , $ attributes ) ) { if ( $ sync ) { $ this -> syncRaw ( ) ; } return true ; } return false ; }
Deletes an attribute on the current entry.

@param string|array $attributes The attribute(s) to delete
@param bool         $sync       Whether to re-sync all attributes

Delete specific values in attributes:

["memberuid" => "username"]

Delete an entire attribute:

["memberuid" => []]

@return bool
Deletes an attribute on the current entry .