diff options
author | Erik Fonnesbeck <efonnes@gmail.com> | 2010-11-18 09:13:42 -0700 |
---|---|---|
committer | Erik Fonnesbeck <efonnes@gmail.com> | 2010-11-18 09:13:42 -0700 |
commit | 8784a3bbbf2d57602d2741f072b26390544434a4 (patch) | |
tree | 517c2136bc7124f283a51c6edc46bf603cb99074 | |
parent | d7bf317824380189dd1176acd6ea1e8bf71650a9 (diff) | |
download | pfsense-8784a3bbbf2d57602d2741f072b26390544434a4.zip pfsense-8784a3bbbf2d57602d2741f072b26390544434a4.tar.gz |
Remove the old field even if empty in rename_field.
-rw-r--r-- | etc/inc/upgrade_config.inc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/etc/inc/upgrade_config.inc b/etc/inc/upgrade_config.inc index 7bf8f2e..8f56bb5 100644 --- a/etc/inc/upgrade_config.inc +++ b/etc/inc/upgrade_config.inc @@ -2228,10 +2228,10 @@ function upgrade_070_to_071() { function rename_field(& $section, $oldname, $newname) { if (is_array($section)) { foreach($section as & $item) { - if (!empty($item[$oldname])) { + if (!empty($item[$oldname])) $item[$newname] = $item[$oldname]; + if (isset($item[$oldname])) unset($item[$oldname]); - } } } } |