fix old cookie causing errors loading layouts

This commit is contained in:
Isaac Connor 2017-12-01 12:30:07 -08:00
parent cb70a3627f
commit 5e953cefea
1 changed files with 1 additions and 1 deletions

View File

@ -78,7 +78,7 @@ if ( isset($_COOKIE['zmMontageLayout']) ) {
$options = array(); $options = array();
$Layout = ''; $Layout = '';
$Positions = ''; $Positions = '';
if ( $layout_id ) { if ( $layout_id and is_numeric($layout_id) and isset($layoutsById[$layout_id]) ) {
$Layout = $layoutsById[$layout_id]; $Layout = $layoutsById[$layout_id];
$Positions = json_decode( $Layout->Positions(), true ); $Positions = json_decode( $Layout->Positions(), true );
} }