diff options
author | Joas Schilling <coding@schilljs.com> | 2018-07-06 15:16:21 +0200 |
---|---|---|
committer | Joas Schilling <coding@schilljs.com> | 2018-07-06 15:16:21 +0200 |
commit | 5541d3dd84f7dab0262fb597649cdbca342635d7 (patch) | |
tree | 74ba763c56fc604fd309833ff40bf37703d03025 | |
parent | 422c805e260f3187fffe7957b2d2f637e20812e3 (diff) | |
download | nextcloud-server-5541d3dd84f7dab0262fb597649cdbca342635d7.tar.gz nextcloud-server-5541d3dd84f7dab0262fb597649cdbca342635d7.zip |
Add visio mimetypes
Signed-off-by: Joas Schilling <coding@schilljs.com>
-rw-r--r-- | lib/private/Repair/RepairMimeTypes.php | 17 | ||||
-rw-r--r-- | resources/config/mimetypealiases.dist.json | 6 | ||||
-rw-r--r-- | resources/config/mimetypemapping.dist.json | 6 | ||||
-rw-r--r-- | version.php | 2 |
4 files changed, 30 insertions, 1 deletions
diff --git a/lib/private/Repair/RepairMimeTypes.php b/lib/private/Repair/RepairMimeTypes.php index 2b259175623..93104ce34e1 100644 --- a/lib/private/Repair/RepairMimeTypes.php +++ b/lib/private/Repair/RepairMimeTypes.php @@ -162,6 +162,19 @@ class RepairMimeTypes implements IRepairStep { return $this->updateMimetypes($updatedMimetypes); } + private function introduceVisioTypes() { + $updatedMimetypes = [ + 'vsdm' => 'application/vnd.visio', + 'vsdx' => 'application/vnd.visio', + 'vssm' => 'application/vnd.visio', + 'vssx' => 'application/vnd.visio', + 'vstm' => 'application/vnd.visio', + 'vstx' => 'application/vnd.visio', + ]; + + return $this->updateMimetypes($updatedMimetypes); + } + /** * Fix mime types */ @@ -191,5 +204,9 @@ class RepairMimeTypes implements IRepairStep { if (version_compare($ocVersionFromBeforeUpdate, '13.0.0.6', '<') && $this->introduceStreamingTypes()) { $out->info('Fixed streaming mime types'); } + + if (version_compare($ocVersionFromBeforeUpdate, '14.0.0.8', '<') && $this->introduceVisioTypes()) { + $out->info('Fixed visio mime types'); + } } } diff --git a/resources/config/mimetypealiases.dist.json b/resources/config/mimetypealiases.dist.json index 2c2ea28059c..eea7081dd71 100644 --- a/resources/config/mimetypealiases.dist.json +++ b/resources/config/mimetypealiases.dist.json @@ -40,6 +40,12 @@ "application/vnd.ms-powerpoint.presentation.macroEnabled.12": "x-office/presentation", "application/vnd.ms-powerpoint.slideshow.macroEnabled.12": "x-office/presentation", "application/vnd.ms-powerpoint.template.macroEnabled.12": "x-office/presentation", + "application/vnd.ms-visio.drawing.macroEnabled.12": "application/vnd.visio", + "application/vnd.ms-visio.drawing": "application/vnd.visio", + "application/vnd.ms-visio.stencil.macroEnabled.12": "application/vnd.visio", + "application/vnd.ms-visio.stencil": "application/vnd.visio", + "application/vnd.ms-visio.template.macroEnabled.12": "application/vnd.visio", + "application/vnd.ms-visio.template": "application/vnd.visio", "application/vnd.ms-word.document.macroEnabled.12": "x-office/document", "application/vnd.ms-word.template.macroEnabled.12": "x-office/document", "application/vnd.oasis.opendocument.presentation": "x-office/presentation", diff --git a/resources/config/mimetypemapping.dist.json b/resources/config/mimetypemapping.dist.json index ef3de4d75dc..2f16e45a4a8 100644 --- a/resources/config/mimetypemapping.dist.json +++ b/resources/config/mimetypemapping.dist.json @@ -176,6 +176,12 @@ "vcf": ["text/vcard"], "vob": ["video/dvd"], "vsd": ["application/vnd.visio"], + "vsdm": ["application/vnd.ms-visio.drawing.macroEnabled.12"], + "vsdx": ["application/vnd.ms-visio.drawing"], + "vssm": ["application/vnd.ms-visio.stencil.macroEnabled.12"], + "vssx": ["application/vnd.ms-visio.stencil"], + "vstm": ["application/vnd.ms-visio.template.macroEnabled.12"], + "vstx": ["application/vnd.ms-visio.template"], "wav": ["audio/wav"], "webm": ["video/webm"], "webp": ["image/webp"], diff --git a/version.php b/version.php index f0a00a9e50b..13501453cc6 100644 --- a/version.php +++ b/version.php @@ -29,7 +29,7 @@ // between betas, final and RCs. This is _not_ the public version number. Reset minor/patchlevel // when updating major/minor version number. -$OC_Version = array(14, 0, 0, 7); +$OC_Version = array(14, 0, 0, 8); // The human readable string $OC_VersionString = '14.0.0 alpha'; |