Aleksander Machniak
2013-05-20 bec9690ff519d33d7ef3f0c8f8f8cf72b4ef059d
program/lib/Roundcube/rcube_config.php
@@ -2,8 +2,6 @@
/*
 +-----------------------------------------------------------------------+
 | program/include/rcube_config.php                                      |
 |                                                                       |
 | This file is part of the Roundcube Webmail client                     |
 | Copyright (C) 2008-2012, The Roundcube Dev Team                       |
 |                                                                       |
@@ -13,7 +11,6 @@
 |                                                                       |
 | PURPOSE:                                                              |
 |   Class to read configuration settings                                |
 |                                                                       |
 +-----------------------------------------------------------------------+
 | Author: Thomas Bruederli <roundcube@gmail.com>                        |
 +-----------------------------------------------------------------------+
@@ -71,11 +68,11 @@
    private function load()
    {
        // load main config file
        if (!$this->load_from_file(RCUBE_CONFIG_DIR . '/main.inc.php'))
        if (!$this->load_from_file(RCUBE_CONFIG_DIR . 'main.inc.php'))
            $this->errors[] = 'main.inc.php was not found.';
        // load database config
        if (!$this->load_from_file(RCUBE_CONFIG_DIR . '/db.inc.php'))
        if (!$this->load_from_file(RCUBE_CONFIG_DIR . 'db.inc.php'))
            $this->errors[] = 'db.inc.php was not found.';
        // load host-specific configuration
@@ -101,11 +98,11 @@
        // fix default imap folders encoding
        foreach (array('drafts_mbox', 'junk_mbox', 'sent_mbox', 'trash_mbox') as $folder)
            $this->prop[$folder] = rcube_charset::convert($this->prop[$folder], RCMAIL_CHARSET, 'UTF7-IMAP');
            $this->prop[$folder] = rcube_charset::convert($this->prop[$folder], RCUBE_CHARSET, 'UTF7-IMAP');
        if (!empty($this->prop['default_folders']))
            foreach ($this->prop['default_folders'] as $n => $folder)
                $this->prop['default_folders'][$n] = rcube_charset::convert($folder, RCMAIL_CHARSET, 'UTF7-IMAP');
                $this->prop['default_folders'][$n] = rcube_charset::convert($folder, RCUBE_CHARSET, 'UTF7-IMAP');
        // set PHP error logging according to config
        if ($this->prop['debug_level'] & 1) {
@@ -156,7 +153,7 @@
        }
        if ($fname) {
            $this->load_from_file(RCUBE_CONFIG_DIR . '/' . $fname);
            $this->load_from_file(RCUBE_CONFIG_DIR . $fname);
        }
    }