diff options
author | Thomas Müller <thomas.mueller@tmit.eu> | 2014-07-31 11:38:29 +0200 |
---|---|---|
committer | Thomas Müller <thomas.mueller@tmit.eu> | 2014-07-31 11:38:29 +0200 |
commit | 4eb2b4e1b087234499f2721bc474fa979a47f1e0 (patch) | |
tree | ef5be6c1204bdc0fe11cf1009684496f4ab426f4 /core | |
parent | c1562057e813ff1dcb0e28b9616c528975fc3b5d (diff) | |
parent | 4a9b0d5465927b0b4cc856cebbc724264ffdd404 (diff) | |
download | nextcloud-server-4eb2b4e1b087234499f2721bc474fa979a47f1e0.tar.gz nextcloud-server-4eb2b4e1b087234499f2721bc474fa979a47f1e0.zip |
Merge pull request #10051 from owncloud/preview-empty-text
Use svg mimeicons for empty text files
Diffstat (limited to 'core')
-rw-r--r-- | core/ajax/preview.php | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/core/ajax/preview.php b/core/ajax/preview.php index edbd41d2db4..d2811f39dd6 100644 --- a/core/ajax/preview.php +++ b/core/ajax/preview.php @@ -30,7 +30,8 @@ if ($maxX === 0 || $maxY === 0) { try { $preview = new \OC\Preview(\OC_User::getUser(), 'files'); - if (!$always and !$preview->isMimeSupported(\OC\Files\Filesystem::getMimeType($file))) { + $info = \OC\Files\Filesystem::getFileInfo($file); + if (!$always and !$preview->isAvailable($info)) { \OC_Response::setStatus(404); } else { $preview->setFile($file); |