Fetch isRead attribute in email delta queries (#1867)
## Description Updating the isRead flag in M365 does not cause the mod time of the item to be updated. This means delta queries will not return items marked as [un]read when isRead is not one of the attributes requested in the $select clause. Explicitly fetch isRead so that we get those items. Further changes will be required to ensure the mod time of the item is something that will not cause kopia-assisted dedupe to skip the item when only the isRead attribute has been changed. ## Does this PR need a docs update or release note? - [ ] ✅ Yes, it's included - [ ] 🕐 Yes, but in a later PR - [x] ⛔ No ## Type of change <!--- Please check the type of change your PR introduces: ---> - [ ] 🌻 Feature - [x] 🐛 Bugfix - [ ] 🗺️ Documentation - [ ] 🤖 Test - [ ] 💻 CI/Deployment - [ ] 🐹 Trivial/Minor ## Issue(s) * closes #1866 ## Test Plan <!-- How will this be tested prior to merging.--> - [x] 💪 Manual - [x] ⚡ Unit test - [ ] 💚 E2E
This commit is contained in:
parent
20bfaee8db
commit
fbbf6aa84c
@ -66,6 +66,7 @@ var (
|
||||
"subject": 4,
|
||||
"webLink": 5,
|
||||
"id": 6,
|
||||
"isRead": 7,
|
||||
}
|
||||
|
||||
fieldsForContacts = map[string]int{
|
||||
|
||||
@ -421,7 +421,7 @@ func FetchMessageIDsFromDirectory(
|
||||
deltaURL string
|
||||
)
|
||||
|
||||
options, err := optionsForFolderMessagesDelta([]string{"id"})
|
||||
options, err := optionsForFolderMessagesDelta([]string{"isRead"})
|
||||
if err != nil {
|
||||
return nil, deltaURL, errors.Wrap(err, "getting query options")
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user