Application cleanup
This commit is contained in:
@@ -14,9 +14,10 @@ class XML extends XML_Core {
|
||||
* Collapse an XML object into a simple array
|
||||
*/
|
||||
public function collapse(XML $xml=NULL) {
|
||||
$result = array();
|
||||
|
||||
if (is_null($xml))
|
||||
$xml = $this;
|
||||
$result = array();
|
||||
|
||||
foreach ($xml->as_array() as $j=>$k) {
|
||||
$v = $xml->$j->value();
|
||||
|
Reference in New Issue
Block a user