From 7e852f604a3c0e38d7a05eea1805e7047e6a0e7b Mon Sep 17 00:00:00 2001 From: Vladimir Y Date: Fri, 19 Oct 2018 10:37:09 +0300 Subject: [PATCH] protonmail: fix "mesage.unread" value storing, fixes #53 --- src/electron-preload/webview/protonmail/lib/database/mail.ts | 2 +- .../webview/protonmail/lib/rest/model/response-entity.ts | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/src/electron-preload/webview/protonmail/lib/database/mail.ts b/src/electron-preload/webview/protonmail/lib/database/mail.ts index bc05cd455..ab919562e 100644 --- a/src/electron-preload/webview/protonmail/lib/database/mail.ts +++ b/src/electron-preload/webview/protonmail/lib/database/mail.ts @@ -39,7 +39,7 @@ export async function buildMail(input: Rest.Model.Message, api: Api): Promise Address({...address, ...buildAddressId(input, "CCList", i)})), bccRecipients: input.BCCList.map((address, i) => Address({...address, ...buildAddressId(input, "BCCList", i)})), attachments: input.Attachments.map(File), - unread: !Boolean(input.IsRead), + unread: Boolean(input.Unread), state: directTypeMapping[input.Type], confidential: isConfindencial(input), replyType: (input.IsReplied || input.IsRepliedAll) && input.IsForwarded diff --git a/src/electron-preload/webview/protonmail/lib/rest/model/response-entity.ts b/src/electron-preload/webview/protonmail/lib/rest/model/response-entity.ts index 6253d1269..21d2e79bc 100644 --- a/src/electron-preload/webview/protonmail/lib/rest/model/response-entity.ts +++ b/src/electron-preload/webview/protonmail/lib/rest/model/response-entity.ts @@ -58,7 +58,6 @@ export interface Message