FolderInformation() use jsonSerialize()

This commit is contained in:
the-djmaze 2023-03-13 10:46:40 +01:00
parent 59b3fe70b6
commit 17b1deb95b
4 changed files with 40 additions and 54 deletions

View file

@ -121,7 +121,7 @@ folderInformation = (folder, list) => {
Remote.request('FolderInformation', (iError, data) => {
if (!iError && data.Result) {
const result = data.Result,
folderFromCache = getFolderFromCacheList(result.folder);
folderFromCache = getFolderFromCacheList(result.name);
if (folderFromCache) {
const oldHash = folderFromCache.etag,
unreadCountChange = (folderFromCache.unreadEmails() !== result.unreadEmails);
@ -167,7 +167,6 @@ folderInformationMultiply = (boot = false) => {
const utc = Date.now();
oData.Result.forEach(item => {
const folder = getFolderFromCacheList(item.name);
if (folder) {
const oldHash = folder.etag,
unreadCountChange = folder.unreadEmails() !== item.unreadEmails;