1
0
Fork 0
mirror of synced 2024-06-29 19:50:26 +12:00

Added method to remove attribute

This commit is contained in:
Eldad Fux 2020-02-10 18:15:18 +02:00
parent c2ae486632
commit dd693d59fc

View file

@ -121,6 +121,26 @@ class Document extends ArrayObject
return $this;
}
/**
* Remove Attribute.
*
* Method for removing a specific field attribute
*
* @param string $key
* @param mixed $value
* @param string $type
*
* @return mixed
*/
public function removeAttribute($key)
{
if(isset($this[$key])) {
unset($this[$key]);
}
return $this;
}
/**
* Search.
*