aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorJulius Härtl <jus@bitgrid.net>2021-10-14 12:58:34 +0200
committerGitHub <noreply@github.com>2021-10-14 12:58:34 +0200
commitacbe4b46c39703f0d3c1e205d4609c7a2607b4b1 (patch)
tree02b3be4a00e255bc4e1ff426c19158c8e1362406 /lib
parented533bd128807ae4e41efb590d59afe05c26668c (diff)
parent2f38781c965904ad10da1953be445fa690adc2cd (diff)
downloadnextcloud-server-acbe4b46c39703f0d3c1e205d4609c7a2607b4b1.tar.gz
nextcloud-server-acbe4b46c39703f0d3c1e205d4609c7a2607b4b1.zip
Merge pull request #29157 from nextcloud/enh/opendocument
Diffstat (limited to 'lib')
-rw-r--r--lib/private/Repair/RepairMimeTypes.php15
1 files changed, 15 insertions, 0 deletions
diff --git a/lib/private/Repair/RepairMimeTypes.php b/lib/private/Repair/RepairMimeTypes.php
index b5c17e85147..61512627258 100644
--- a/lib/private/Repair/RepairMimeTypes.php
+++ b/lib/private/Repair/RepairMimeTypes.php
@@ -192,6 +192,17 @@ class RepairMimeTypes implements IRepairStep {
return $this->updateMimetypes($updatedMimetypes);
}
+ private function introduceFlatOpenDocumentType() {
+ $updatedMimetypes = [
+ "fodt" => "application/vnd.oasis.opendocument.text-flat-xml",
+ "fods" => "application/vnd.oasis.opendocument.spreadsheet-flat-xml",
+ "fodg" => "application/vnd.oasis.opendocument.graphics-flat-xml",
+ "fodp" => "application/vnd.oasis.opendocument.presentation-flat-xml",
+ ];
+
+ return $this->updateMimetypes($updatedMimetypes);
+ }
+
private function introduceOrgModeType() {
$updatedMimetypes = [
'org' => 'text/org'
@@ -245,5 +256,9 @@ class RepairMimeTypes implements IRepairStep {
if (version_compare($ocVersionFromBeforeUpdate, '21.0.0.7', '<') && $this->introduceOrgModeType()) {
$out->info('Fixed orgmode mime types');
}
+
+ if (version_compare($ocVersionFromBeforeUpdate, '23.0.0.2', '<') && $this->introduceFlatOpenDocumentType()) {
+ $out->info('Fixed Flat OpenDocument mime types');
+ }
}
}