mirror of
https://github.com/Foundry376/Mailspring.git
synced 2025-02-25 00:25:03 +08:00
[local-sync, cloud-api] Add logic to handle thread metadata
Summary: [cloud-api] Based on the passed in `messageIds`, it finds any existing thread metadata that might be under a different thread id. If it realizes there are actually multiple threads that should be the same thread, (due to getting a missing message link), it reconciles all of them. [local-sync] Return `message_ids` in `Thread.toJSON()` See D3879 for tests N1 Pairing: D3875 Test Plan: unit tests, local testing soon Reviewers: juan, evan Reviewed By: evan Differential Revision: https://phab.nylas.com/D3880
This commit is contained in:
parent
1e74be3b94
commit
8287f4116f
1 changed files with 1 additions and 0 deletions
|
@ -198,6 +198,7 @@ module.exports = (sequelize, Sequelize) => {
|
|||
const response = {
|
||||
id: `${this.id}`,
|
||||
object: 'thread',
|
||||
message_ids: this.messages.map(m => m.id),
|
||||
folders: this.folders.map(f => f.toJSON()),
|
||||
labels: this.labels.map(l => l.toJSON()),
|
||||
account_id: this.accountId,
|
||||
|
|
Loading…
Reference in a new issue