diff --git a/qtism/data/storage/xml/marshalling/AssessmentSectionMarshaller.php b/qtism/data/storage/xml/marshalling/AssessmentSectionMarshaller.php index b8ec62ff4..63f3d7550 100644 --- a/qtism/data/storage/xml/marshalling/AssessmentSectionMarshaller.php +++ b/qtism/data/storage/xml/marshalling/AssessmentSectionMarshaller.php @@ -71,8 +71,11 @@ protected function unmarshallChildrenKnown(DOMElement $element, QtiComponentColl // Deal with selection elements. $selectionElements = static::getChildElementsByTagName($element, 'selection'); if (count($selectionElements) == 1) { - $marshaller = $this->getMarshallerFactory()->createMarshaller($selectionElements[0]); - $object->setSelection($marshaller->unmarshall($selectionElements[0])); + $select = intval($selectionElements[0]->getAttribute('select')); + if ($select > 0) { + $marshaller = $this->getMarshallerFactory()->createMarshaller($selectionElements[0]); + $object->setSelection($marshaller->unmarshall($selectionElements[0])); + } } // Deal with ordering elements.