Merge branch 'master' of ssh://p0m.fr:6224/git/nemubot_askweb

This commit is contained in:
Bertrand 2012-05-22 10:45:46 +02:00
commit 94582f29d9

View File

@ -23,10 +23,8 @@ class QuestionsFile
$this->treeXML = new DOMDocument('1.0', 'UTF-8'); $this->treeXML = new DOMDocument('1.0', 'UTF-8');
$this->treeXML->formatOutput = true; $this->treeXML->formatOutput = true;
if (is_file($this->filename)) if (@$this->treeXML->load($this->filename))
{ {
$this->treeXML->load($this->filename);
$root_nodes = $this->treeXML->getElementsByTagName("questions"); $root_nodes = $this->treeXML->getElementsByTagName("questions");
if ($root_node->length > 0) if ($root_node->length > 0)
$this->root_node = $root_nodes->item(0); $this->root_node = $root_nodes->item(0);