Adds missing registration of mixins to support 'forEachAsync' (#1051)
Esse commit está contido em:
@@ -2,6 +2,7 @@ import {
|
||||
app, ipcMain, BrowserWindow, BrowserWindowConstructorOptions,
|
||||
Menu, MenuItemConstructorOptions,
|
||||
} from "electron";
|
||||
import registerMixins from "../registerMixins";
|
||||
import { IpcMainProxy } from "./common/ipcMainProxy";
|
||||
import LocalFileSystem from "./providers/storage/localFileSystem";
|
||||
|
||||
@@ -124,6 +125,8 @@ function registerContextMenu(browserWindow: BrowserWindow): void {
|
||||
Menu.setApplicationMenu(menu);
|
||||
}
|
||||
|
||||
registerMixins();
|
||||
|
||||
// This method will be called when Electron has finished
|
||||
// initialization and is ready to create browser windows.
|
||||
// Some APIs can only be used after this event occurs.
|
||||
|
||||
@@ -95,7 +95,6 @@ export default class LocalFileSystem implements IStorageProvider {
|
||||
|
||||
public async listFiles(folderPath: string): Promise<string[]> {
|
||||
const normalizedPath = path.normalize(folderPath);
|
||||
console.log(`Listing files from ${normalizedPath}`);
|
||||
const files = await this.listItems(normalizedPath, (stats) => !stats.isDirectory());
|
||||
const directories = await this.listItems(normalizedPath, (stats) => stats.isDirectory());
|
||||
await directories.forEachAsync(async (directory) => {
|
||||
|
||||
Referência em uma Nova Issue
Bloquear um usuário