Use location as is when displaying thumbnails inside downloads dropdown in MAS builds (#2536)

This commit is contained in:
Tasos Boulis
2023-02-02 19:37:04 +02:00
committed by GitHub
parent 61a0b41d47
commit 9b45935bee

View File

@@ -1,8 +1,7 @@
// Copyright (c) 2016-present Mattermost, Inc. All Rights Reserved.
// See LICENSE.txt for license information.
import path from 'path';
import {app, BrowserView, BrowserWindow, ipcMain, IpcMainEvent, IpcMainInvokeEvent} from 'electron';
import {BrowserView, BrowserWindow, ipcMain, IpcMainEvent, IpcMainInvokeEvent} from 'electron';
import log from 'electron-log';
@@ -212,13 +211,6 @@ export default class DownloadsDropdownView {
}
getDownloadImageThumbnailLocation = (event: IpcMainInvokeEvent, location: string) => {
// eslint-disable-next-line no-undef
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
// @ts-ignore
if (!__IS_MAC_APP_STORE__) {
return location;
}
return path.resolve(app.getPath('temp'), path.basename(location));
return location;
}
}