[local-sync] Fix a couple bugs that popped up while sending

- Pass in the account when creating an ImapConnection
- Wrap the return value of the SendMessage task in an object
This commit is contained in:
Halla Moore 2016-12-16 15:43:39 -08:00
parent 5a1fb3c9ad
commit b46ffd4a3f
2 changed files with 2 additions and 1 deletions

View file

@ -126,6 +126,7 @@ class SyncWorker {
db: this._db,
settings: Object.assign({}, settings, credentials),
logger: this._logger,
account: this._account,
});
conn.on('mail', () => {

View file

@ -48,7 +48,7 @@ class SendMessageIMAP extends SyncbackTask {
// actually did
logger.error(err, 'SendMessage: Could not sent message to sent folder')
}
return message.toJSON()
return {message: message.toJSON()}
}
}