Skip to content

Commit

Permalink
Merge pull request #3920 from nextcloud/backport/3918/stable3.0
Browse files Browse the repository at this point in the history
[stable3.0] Fix: Inconsistencies due to ALTREP parameter
  • Loading branch information
st3iny committed Jan 28, 2022
2 parents 2cb2169 + 88645fd commit f5ab40b
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/store/calendarObjectInstance.js
Original file line number Diff line number Diff line change
Expand Up @@ -311,6 +311,14 @@ const mutations = {
* @param {string} data.description New description to set
*/
changeDescription(state, { calendarObjectInstance, description }) {
// ALTREP parameter is not set by NC calendar, but by CalDAV clients like Thunderbird.
// To avoid inconsistencies, remove ALTREP parameter upon modification.
const descriptionProperty = calendarObjectInstance.eventComponent.getFirstProperty('Description')
if (descriptionProperty) {
if (descriptionProperty.hasParameter('ALTREP')) {
descriptionProperty.deleteParameter('ALTREP')
}
}
calendarObjectInstance.eventComponent.description = description
calendarObjectInstance.description = description
},
Expand Down

0 comments on commit f5ab40b

Please sign in to comment.