mirror of
https://github.com/Foundry376/Mailspring.git
synced 2025-09-08 13:44:53 +08:00
fix(build): linter errors
This commit is contained in:
parent
c2cf89026e
commit
040c3bc45a
2 changed files with 8 additions and 8 deletions
|
@ -19,14 +19,14 @@ _flatMapJoiningMessages = ($threadsResultSet) =>
|
|||
# the new threads at once. (This is a performance optimization -it's about
|
||||
# ~80msec faster than making 100 queries for 100 new thread ids separately.)
|
||||
$threadsResultSet.flatMapLatest (threadsResultSet) =>
|
||||
missingIds = threadsResultSet.ids().filter (id) -> not $messagesResultSets[id]
|
||||
if missingIds.length is 0
|
||||
promise = Promise.resolve([threadsResultSet, []])
|
||||
else
|
||||
promise = DatabaseStore.findAll(Message, threadId: missingIds).then (messages) =>
|
||||
Promise.resolve([threadsResultSet, messages])
|
||||
missingIds = threadsResultSet.ids().filter (id) -> not $messagesResultSets[id]
|
||||
if missingIds.length is 0
|
||||
promise = Promise.resolve([threadsResultSet, []])
|
||||
else
|
||||
promise = DatabaseStore.findAll(Message, threadId: missingIds).then (messages) =>
|
||||
Promise.resolve([threadsResultSet, messages])
|
||||
|
||||
return Rx.Observable.fromPromise(promise)
|
||||
return Rx.Observable.fromPromise(promise)
|
||||
|
||||
# 3. when that finishes, we group the loaded messsages by threadId and create
|
||||
# the missing observables. Creating a query subscription would normally load
|
||||
|
|
|
@ -260,7 +260,7 @@ class Application
|
|||
# for this function to finish so it can get the return value via ipc.
|
||||
# Unfortunately since this function destroys the main window
|
||||
# immediately, an error will be thrown.
|
||||
setTimeout(() =>
|
||||
setTimeout( =>
|
||||
return if @_databasePhase is 'close'
|
||||
@setDatabasePhase('close')
|
||||
@windowManager.destroyAllWindows()
|
||||
|
|
Loading…
Add table
Reference in a new issue