[FIX] Stalwart: fix jmap 0.7.0 msg_header keys(message-id,message_id) #944
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Pull Request Description
Title: Update Draft Saving Functionality for Stalwart 0.7.0 Compatibility
Description:
Issue:
In Stalwart release 0.5.0, the message ID field was consistently labeled as "message-id" in the response data when saving drafts. However, with the release of Stalwart 0.7.0, there has been a change where the message ID field is now labeled as "message_id". This inconsistency has caused issues when attempting to save drafts as our codebase was expecting the previous format.
Solution:
To ensure compatibility with Stalwart 0.7.0 and future versions, this pull request updates the draft saving functionality to handle both "message-id" and "message_id" fields in the response data. The code now checks for the existence of both keys and compares their values accordingly. This change allows our application to seamlessly handle drafts saved using both versions of Stalwart.
Changes Made:
This pull request aims to resolve the compatibility issue with Stalwart 0.7.0 and improve the robustness of our draft saving feature for future releases.
Related Issue: #931