]> source.dussan.org Git - nextcloud-server.git/commitdiff
Update repair step apply new opendocument template mimes 22552/head
authorJulius Härtl <jus@bitgrid.net>
Fri, 4 Sep 2020 06:42:32 +0000 (08:42 +0200)
committerJulius Härtl <jus@bitgrid.net>
Fri, 4 Sep 2020 06:42:32 +0000 (08:42 +0200)
Signed-off-by: Julius Härtl <jus@bitgrid.net>
lib/private/Repair/RepairMimeTypes.php
version.php

index b6b6ceed104ca91eb014f1f97af9e422e4abd819..60a7df25f63956ecdc490956a5fed3af7905783d 100644 (file)
@@ -191,6 +191,17 @@ class RepairMimeTypes implements IRepairStep {
                return $this->updateMimetypes($updatedMimetypes);
        }
 
+       private function introduceOpenDocumentTemplates() {
+               $updatedMimetypes = [
+                       'ott' => 'application/vnd.oasis.opendocument.text-template',
+                       'ots' => 'application/vnd.oasis.opendocument.spreadsheet-template',
+                       'otp' => 'application/vnd.oasis.opendocument.presentation-template',
+                       'otg' => 'application/vnd.oasis.opendocument.graphics-template',
+               ];
+
+               return $this->updateMimetypes($updatedMimetypes);
+       }
+
        /**
         * Fix mime types
         */
@@ -227,5 +238,9 @@ class RepairMimeTypes implements IRepairStep {
                if (version_compare($ocVersionFromBeforeUpdate, '14.0.0.10', '<') && $this->introduceComicbookTypes()) {
                        $out->info('Fixed comicbook mime types');
                }
+
+               if (version_compare($ocVersionFromBeforeUpdate, '20.0.0.5', '<') && $this->introduceOpenDocumentTemplates()) {
+                       $out->info('Fixed OpenDocument template mime types');
+               }
        }
 }
index da3c3477ae4037528c9d427b06721640bbd55b20..9457db90c7cd54d5a40c17da63095aea4157f1e7 100644 (file)
@@ -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 = [20, 0, 0, 4];
+$OC_Version = [20, 0, 0, 5];
 
 // The human readable string
 $OC_VersionString = '20.0.0 Beta 2';