Skip to content

Commit

Permalink
Fix EZP-23194: Notice on the final step of setup wizard
Browse files Browse the repository at this point in the history
> https://jira.ez.no/browse/EZP-23194

Added a safeguard clause.
  • Loading branch information
lolautruche committed Nov 12, 2014
1 parent 1d0bba6 commit 59d3634
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions datatypes/ezpage/ezpagetype.php
Expand Up @@ -73,14 +73,14 @@ function serializeContentClassAttribute( $classAttribute, $attributeNode, $attri
* Unserialize contentclass attribute
*
* @param eZContentClassAttribute $classAttribute
* @param DOMNode $attributeNode
* @param DOMNode $attributeParametersNode
* @param DOMElement $attributeNode
* @param DOMElement $attributeParametersNode
*/
function unserializeContentClassAttribute( $classAttribute, $attributeNode, $attributeParametersNode )
{
$defaultZoneLayout = $attributeParametersNode->getElementsByTagName( 'default-layout' )->item( 0 )->textContent;
if ( $defaultZoneLayout !== false )
$classAttribute->setAttribute( self::DEFAULT_ZONE_LAYOUT_FIELD, $defaultZoneLayout );
$defaultZoneLayoutItem = $attributeParametersNode->getElementsByTagName( 'default-layout' )->item( 0 );
if ( $defaultZoneLayoutItem !== null && $defaultZoneLayoutItem->textContent !== false )
$classAttribute->setAttribute( self::DEFAULT_ZONE_LAYOUT_FIELD, $defaultZoneLayoutItem->textContent );
}

/**
Expand Down

0 comments on commit 59d3634

Please sign in to comment.