From: Tim Otten Date: Mon, 20 May 2013 03:32:13 +0000 (-0400) Subject: CRM_Utils_Migrate_Import - Fix static warning X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=8080d1e09d6f04533f43d53de8ec4b429fe365d3;p=civicrm-core.git CRM_Utils_Migrate_Import - Fix static warning --- diff --git a/CRM/Utils/Migrate/Import.php b/CRM/Utils/Migrate/Import.php index d2c312d65a..35990fc723 100644 --- a/CRM/Utils/Migrate/Import.php +++ b/CRM/Utils/Migrate/Import.php @@ -39,7 +39,10 @@ class CRM_Utils_Migrate_Import { function run($file) { // read xml file - $dom = DomDocument::load($file); + $dom = new DomDocument(); + if (! $dom->load($file)) { + throw new CRM_Core_Exception("Failed to parse XML file \"$file\""); + } $dom->xinclude(); $xml = simplexml_import_dom($dom);