From 02df7e739a60f19d9fb9af1914635727680f2aad Mon Sep 17 00:00:00 2001 From: Xymorot Date: Mon, 4 Jan 2021 22:12:37 +0100 Subject: [PATCH] fix: make it possible to cancel the selecting of folder when getting nhentai favorites --- src/main/modules/nhentai/nhentai-ipc-controller.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/main/modules/nhentai/nhentai-ipc-controller.ts b/src/main/modules/nhentai/nhentai-ipc-controller.ts index 9f795d6..000fe62 100644 --- a/src/main/modules/nhentai/nhentai-ipc-controller.ts +++ b/src/main/modules/nhentai/nhentai-ipc-controller.ts @@ -26,6 +26,10 @@ export class NhentaiIpcController implements IIpcController { title: this.translator.t('Select torrent file save location'), }); + if (result.canceled) { + return; + } + const favoritesStream = await this.nhentaiApi.getFavorites(); return new Promise((resolve) => {