Not sure if this belongs to panels or not but posting here first. Whenever I initially install my site or flush my caches I get the following error:
Notice: Undefined index: items in panels_flexible_panels() (line 257 of C:\Desktop\Sites\drupal_wet\profiles\wetkit\modules\contrib\panels\plugins\layouts\flexible\flexible.inc).
Warning: Invalid argument supplied for foreach() in panels_flexible_panels() (line 257 of C:\Desktop\Sites\drupal_wet\profiles\wetkit\modules\contrib\panels\plugins\layouts\flexible\flexible.inc).
Tracing the issue to line 384 of ds.registry.inc
if ($layout['name'] != 'flexible') {
$regions = panels_flexible_panels(array(), array(), $layout);
$layouts['panels-' . $key] = array(
Which then calls in panels (latest dev) flexible.inc
function panels_flexible_panels($display, $settings, $layout) {
$items = array();
panels_flexible_convert_settings($settings, $layout);
foreach ($settings['items'] as $id => $item) {
// Remove garbage values.
if (!isset($item['type'])) {
unset($items[$id]);
}
else if ($item['type'] == 'region') {
$items[$id] = $item['title'];
}
}
return $items;
}
When I disable DS the error no longer presents itself
Comments
Comment #0.0
sylus CreditAttribution: sylus commentedMod
Comment #0.1
sylus CreditAttribution: sylus commentedMod
Comment #1
mgiffordDoes it show up anywhere other than the install?
I saw it too when installing the distro.
Comment #2
swentel CreditAttribution: swentel commentedtagging
Comment #3
netsensei CreditAttribution: netsensei commentedWe've been looking at this.
We do a
$panel_layouts = panels_get_layouts();
, then loop through the results while executingpanels_flexible_panels(array(), array(), $layout)
without altering the$layout
(line363 through 384 in includes/ds.registry.inc)In
panels_flexible_panels()
, we pass$settings/code> (by reference) and <code>$layout
topanels_flexible_convert_settings($settings, $layout);
where the$settings['items']
are set. (flexible.inc)Unless
$layout['layout']->settings
is empty, $settings['items'] should always exist.So this looks more like a Panels problem then a DS problem.
Moving this.
Comment #3.0
netsensei CreditAttribution: netsensei commentedMod
Comment #4
drupalok CreditAttribution: drupalok commentedsame problem here... any solution`?
Comment #5
freality CreditAttribution: freality commentedI just posted a patch at https://drupal.org/comment/8565917#comment-8565917 with I believe addresses the same issue.