-
Type:
Bug
-
Resolution: Fixed
-
Priority:
Low
-
Affects Version/s: 10.2.13, 10.2.15
-
Component/s: Apps - Team Calendar
-
1
-
Severity 3 - Minor
Issue Summary
In Confluence 10.2.x, users are unable to modify existing Team Calendar macros. When attempting to add or remove a calendar within the macro editor, clicking the "Save" button closes the dialog but fails to persist any changes.
This is caused by a regression in the macro's JavaScript (batch.js), which attempts to call .trim() on a non-string object (typically an array or a malformed resource identifier), resulting in an unhandled TypeError that aborts the save process.
Steps to Reproduce
- Create a Confluence page and add a Team Calendar macro.
- Open the browser developer tools (F12) and execute the following command in the Console to simulate a malformed resource/locale configuration: window.WRM.__localeOverride = ["en-US"];
- Open the Team Calendar macro editor on the page.
- Attempt to add or remove a calendar from the selection.
- Click the Save button on the macro dialog.
- Observe that the dialog closes, but the changes are not reflected in the editor or after publishing; if you reopen the macro editor, the new calendar selection is not saved.
Expected Results
The macro should process the selection change, update the underlying XHTML storage format, and persist the changes when the page is saved.
Actual Results
The JavaScript execution crashes silently in the background. The "Save" button action is aborted, and the macro remains in its original state.
The following exception is thrown in the Browser Console:
Uncaught TypeError: (f.auiSelect2(...) || "").trim is not a function
at HTMLInputElement.<anonymous> (batch.js:232:40)
at HTMLInputElement.dispatch (batch.js:5202:27)
at elemData.handle (batch.js:5006:28)
at Object.trigger (batch.js:8686:12)
at i.triggerChange (batch.js:3707:18195)
at i.onSelect (batch.js:3707:49910)
The below exception is observed in the atlassian-confluence.log (Backend Trigger):
ERROR [Caesium-1-4] [render.xhtml.links.XhtmlOutgoingLinksExtractor] extract Error unmarshalling resource identifier fragment.
com.atlassian.confluence.content.render.xhtml.XhtmlException: com.atlassian.confluence.content.render.xhtml.XhtmlException: Missing required attribute: {http://atlassian.com/resource/identifier}value
at com.atlassian.confluence.content.render.xhtml.storage.resource.identifiers.StorageResourceIdentifierUnmarshaller.unmarshal(StorageResourceIdentifierUnmarshaller.java:66)
at com.atlassian.confluence.impl.content.DefaultContentLinkManager.process(DefaultContentLinkManager.java:150)
Workaround
Currently, there is no known workaround for this behavior. A workaround will be added here when available.
(Note: While manually forcing a string conversion via browser developer tools can bypass the error, it is not considered a viable workaround.