Skip to content

Commit

Permalink
prevent issues where empty location values overwrite existing menu it…
Browse files Browse the repository at this point in the history
…ems with empty location values
  • Loading branch information
David McReynolds committed Jun 3, 2014
1 parent f2d255d commit a63993d
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions fuel/modules/fuel/models/fuel_navigation_model.php
Original file line number Diff line number Diff line change
Expand Up @@ -486,6 +486,12 @@ public function on_before_clean($values)
$values['location'] = str_replace(array('____', '___', '_X_'), array('/', '#', '.'), $values['location']);
}

// prevents issues where empty location values overwrite existing menu items with empty location values
if (empty($values['location']))
{
$values['location'] = '/';
}

if (empty($values['language']))
{
$CI =& get_instance();
Expand Down

0 comments on commit a63993d

Please sign in to comment.