dev/Magento/Identifier.php
public function markSections(array $sectionsData, $sectionNames = null, $updateIds = false)
    {
        if (!$sectionNames) {
            $sectionNames = array_keys($sectionsData);
        }
        $markId = $this->initMark($updateIds);

        foreach ($sectionNames as $name) {
            if ($updateIds || !array_key_exists(self::SECTION_KEY, $sectionsData[$name])) {
                $sectionsData[$name][self::SECTION_KEY] = $markId;
            }
            if(!isset($sectionsData[$name])){
                $sectionsData[$name] = [];
            }
        }
        return $sectionsData;
    }
public function markSections(array $sectionsData, $sectionNames = null, $updateIds = false)
    {
        if (!$sectionNames) {
            $sectionNames = array_keys($sectionsData);
        }
        $markId = $this->initMark($updateIds);

        foreach ($sectionNames as $name) {
            if ($updateIds || !array_key_exists(self::SECTION_KEY, $sectionsData[$name])) {
                $sectionsData[$name][self::SECTION_KEY] = $markId;
            }
            if(!isset($sectionsData[$name])){
                $sectionsData[$name] = [];
            }
        }
        return $sectionsData;
    }
public function markSections ( array $ sectionsData , $ sectionNames = null , $ updateIds = false ) { if ( ! $ sectionNames ) { $ sectionNames = array_keys ( $ sectionsData ) ; } $ markId = $ this -> initMark ( $ updateIds ) ; foreach ( $ sectionNames as $ name ) { if ( $ updateIds || ! array_key_exists ( self :: SECTION_KEY , $ sectionsData [ $ name ] ) ) { $ sectionsData [ $ name ] [ self :: SECTION_KEY ] = $ markId ; } if ( ! isset ( $ sectionsData [ $ name ] ) ) { $ sectionsData [ $ name ] = [ ] ; } } return $ sectionsData ; }
Mark sections with data id

@param array $sectionsData
@param null $sectionNames
@param bool $updateIds
@return array
Mark sections with data id