Move to OC::$configDif

This commit is contained in:
Roeland Jago Douma 2015-07-10 13:37:26 +02:00
parent 895d29adf1
commit 8cac236135
1 changed files with 3 additions and 3 deletions

View File

@ -424,12 +424,12 @@ class OC_Helper {
*/
static public function getMimetypeDetector() {
if (!self::$mimetypeDetector) {
$dist = file_get_contents(OC::$SERVERROOT . '/config/mimetypemapping.dist.json');
$dist = file_get_contents(OC::$configDir . '/mimetypemapping.dist.json');
$mimetypemapping = get_object_vars(json_decode($dist));
//Check if need to load custom mappings
if (file_exists(OC::$SERVERROOT . '/config/mimetypemapping.json')) {
$custom = file_get_contents(OC::$SERVERROOT . '/config/mimetypemapping.json');
if (file_exists(OC::$configDir . '/mimetypemapping.json')) {
$custom = file_get_contents(OC::$configDir . '/mimetypemapping.json');
$custom_mapping = get_object_vars(json_decode($custom));
$mimetypemapping = array_merge($mimetypemapping, $custom_mapping);
}