* @return mixed
*/
function arrayToString( $list ) {
- if ( ! is_array( $list ) ) {
+ if( is_object( $list ) ) {
+ $class = get_class( $list );
+ return "($class)";
+ } elseif ( ! is_array( $list ) ) {
return $list;
} else {
$class = get_class( $list[0] );
return false;
}
- $xml = simplexml_load_file( $entries, "SimpleXMLElement", LIBXML_NOWARNING );
+ // SimpleXml whines about the xmlns...
+ wfSuppressWarnings();
+ $xml = simplexml_load_file( $entries );
+ wfRestoreWarnings();
if( $xml ) {
foreach( $xml->entry as $entry ) {