yiisoft/yii — pull request #1454 by resurtm (2012-09-21 16:45:03+00:00)
Title: Fixes #1393: CFileHelper::getMimeTypeByExtension() used to treat $magicFile parameter as array with MIME-types, but not the string containing path of the file with MIME-types as it should be.

Fixes #1393: CFileHelper::getMimeTypeByExtension() used to treat $magicFile parameter as array with MIME-types, but not the string containing path of the file with MIME-types as it should be.

Testing code:
```php
'application/json',
'txb'=>'text/plain2',
);
```

Results:
```
null
'application/json'
'text/plain2'
'text/plain'
```