| Total Complexity | 5 |
| Total Lines | 39 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 5 | class MimeContentType extends AbstractDetector |
||
| 6 | { |
||
| 7 | |||
| 8 | /** |
||
| 9 | * Try to detect mime type of image using *mime_content_type()*. |
||
| 10 | * |
||
| 11 | * Returns: |
||
| 12 | * - mime type (string) (if it is in fact an image, and type could be determined) |
||
| 13 | * - false (if it is not an image type that the server knowns about) |
||
| 14 | * - null (if nothing can be determined) |
||
| 15 | * |
||
| 16 | * @param string $filePath The path to the file |
||
| 17 | * @return string|false|null mimetype (if it is an image, and type could be determined), |
||
| 18 | * false (if it is not an image type that the server knowns about) |
||
| 19 | * or null (if nothing can be determined) |
||
| 20 | */ |
||
| 21 | 3 | protected function doDetect($filePath) |
|
| 46 |