diff options
author | Aleksander Machniak <alec@alec.pl> | 2014-06-21 15:41:40 +0200 |
---|---|---|
committer | Thomas Bruederli <thomas@roundcube.net> | 2014-07-31 14:16:05 +0200 |
commit | d1749659d25c5b68600aef3557284cedff8dded1 (patch) | |
tree | e3e9459679ec55dbfedb3531a60d814992eab9c9 /program/steps/settings/folders.inc | |
parent | 057444bd415a3b0fef503f88f44d29b95e50d64d (diff) |
Backported option to set default message list mode - default_list_mode (#1487312)
Diffstat (limited to 'program/steps/settings/folders.inc')
-rw-r--r-- | program/steps/settings/folders.inc | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/program/steps/settings/folders.inc b/program/steps/settings/folders.inc index b09ea03ce..4f92298e3 100644 --- a/program/steps/settings/folders.inc +++ b/program/steps/settings/folders.inc @@ -407,16 +407,17 @@ function rcmail_rename_folder($oldname, $newname) $a_threaded = (array) $RCMAIL->config->get('message_threading', array()); $oldprefix = '/^' . preg_quote($oldname . $delimiter, '/') . '/'; - foreach (array_keys($a_threaded) as $key) { + foreach ($a_threaded as $key => $val) { if ($key == $oldname) { unset($a_threaded[$key]); - $a_threaded[$newname] = true; + $a_threaded[$newname] = $val; } else if (preg_match($oldprefix, $key)) { unset($a_threaded[$key]); - $a_threaded[preg_replace($oldprefix, $newname.$delimiter, $key)] = true; + $a_threaded[preg_replace($oldprefix, $newname.$delimiter, $key)] = $val; } } + $RCMAIL->user->save_prefs(array('message_threading' => $a_threaded)); // #1488692: update session |