Aleksander Machniak
2012-09-02 6c9fe3d894bd065df3e4cd16ff9f661ad7194856
program/steps/settings/folders.inc
@@ -47,8 +47,8 @@
        if ($result) {
            // Handle subscription of protected folder (#1487656)
            if ($CONFIG['protect_default_folders'] == true
                && in_array($mbox, $CONFIG['default_folders'])
            if ($RCMAIL->config->get('protect_default_folders')
                && in_array($mbox, (array)$RCMAIL->config->get('default_folders'))
            ) {
                $OUTPUT->command('disable_subscription', $mbox);
            }
@@ -324,8 +324,8 @@
                }
            }
        }
        // check if the folder is shared, then disable subscription option on it
        if (!$disabled && $folder['virtual'] && !empty($namespace)) {
        // check if the folder is shared, then disable subscription option on it (if not subscribed already)
        if (!$disabled && !$subscribed && $folder['virtual'] && !empty($namespace)) {
            $tmp_ns = array_merge((array)$namespace['other'], (array)$namespace['shared']);
            foreach ($tmp_ns as $item) {
                if (strpos($folder['id'], $item[0]) === 0) {
@@ -414,7 +414,10 @@
$OUTPUT->set_pagetitle(rcube_label('folders'));
$OUTPUT->include_script('list.js');
$OUTPUT->set_env('quota', $STORAGE->get_capability('QUOTA'));
$OUTPUT->set_env('prefix_ns', $STORAGE->get_namespace('prefix'));
if ($STORAGE->get_capability('QUOTA')) {
    $OUTPUT->set_env('quota', true);
}
// add some labels to client
$OUTPUT->add_label('deletefolderconfirm', 'purgefolderconfirm', 'folderdeleting',