aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorCarl Schwan <carl@carlschwan.eu>2022-12-07 21:22:08 +0100
committerGitHub <noreply@github.com>2022-12-07 21:22:08 +0100
commit7ac2d310a78dc26870bafa48d9dfa0355018415a (patch)
tree37c9bfbb9fa2870e33884a711d3c4077c4ddb28f /lib
parent3c8fb59fa46cce8e570e0b7d6965ce98a1c0ef74 (diff)
parent582f07c8fc47d4a775f05fbaad32269753d944f0 (diff)
downloadnextcloud-server-7ac2d310a78dc26870bafa48d9dfa0355018415a.tar.gz
nextcloud-server-7ac2d310a78dc26870bafa48d9dfa0355018415a.zip
Merge pull request #35176 from bjornfor/add-asciidoc-mime-type
Add text/asciidoc mimetype
Diffstat (limited to 'lib')
-rw-r--r--lib/private/Repair/RepairMimeTypes.php13
1 files changed, 13 insertions, 0 deletions
diff --git a/lib/private/Repair/RepairMimeTypes.php b/lib/private/Repair/RepairMimeTypes.php
index 5b216331dc7..5f3531ea79c 100644
--- a/lib/private/Repair/RepairMimeTypes.php
+++ b/lib/private/Repair/RepairMimeTypes.php
@@ -106,6 +106,15 @@ class RepairMimeTypes implements IRepairStep {
return $count;
}
+ private function introduceAsciidocType() {
+ $updatedMimetypes = [
+ 'adoc' => 'text/asciidoc',
+ 'asciidoc' => 'text/asciidoc',
+ ];
+
+ return $this->updateMimetypes($updatedMimetypes);
+ }
+
private function introduceImageTypes() {
$updatedMimetypes = [
'jp2' => 'image/jp2',
@@ -273,5 +282,9 @@ class RepairMimeTypes implements IRepairStep {
if (version_compare($ocVersionFromBeforeUpdate, '25.0.0.2', '<') && $this->introduceOnlyofficeFormType()) {
$out->info('Fixed ONLYOFFICE Forms OpenXML mime types');
}
+
+ if (version_compare($ocVersionFromBeforeUpdate, '26.0.0.1', '<') && $this->introduceAsciidocType()) {
+ $out->info('Fixed AsciiDoc mime types');
+ }
}
}