Merge pull request #21028 from nextcloud/backport/20629/stable19

[stable19] Don't load text file preview when text app is available (Fixes: #20615)
This commit is contained in:
Morris Jobke 2020-05-20 13:54:17 +02:00 committed by GitHub
commit 138eddc0f1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 1 deletions

View File

@ -152,7 +152,8 @@ OCA.Sharing.PublicApp = {
img.attr('src', $('#downloadURL').val());
imgcontainer.appendTo('#imgframe');
} else if (mimetype.substr(0, mimetype.indexOf('/')) === 'text' && window.btoa) {
if (OC.appswebroots['files_texteditor'] !== undefined) {
if (OC.appswebroots['files_texteditor'] !== undefined ||
OC.appswebroots['text'] !== undefined) {
// the text editor handles the previewing
return;
}