When adding a personal relationship to a person's record, relationship attributes such as Carer, Emergency Contact, and Next of Kin can save against the wrong relationship record. This happens when a user clicks the text label beside a checkbox rather than the checkbox itself, and has interacted with both the Personal Relationships and Suggested Relationships tabs in the same session.
This article explains what causes the bug, how to replicate it, the risks involved, and how to avoid it until a fix is released.
β οΈ Important: The bug is silent. You will not receive a warning or error message if attributes save incorrectly. Always check the saved record after adding a relationship to confirm the attributes are correct.
What is happening
The Add Personal Relationship dialog has two tabs: Personal Relationships and Suggested Relationships. Both tabs include checkboxes for setting relationship attributes such as Carer, Emergency Contact, and Next of Kin.
Both tabs use identical checkbox labels behind the scenes. Because both tabs load into the page at the same time, even when one is hidden from view, the page contains two sets of checkboxes with the same names. When you click the text label next to a checkbox, the page cannot determine which checkbox you intended to select. This can result in the wrong checkbox being selected, in the wrong tab, on the wrong relationship.
Clicking directly on the checkbox itself works as expected. The bug only triggers when you click the text label beside the checkbox.
The result is that relationship attributes can save to the wrong person's relationship record, without any error message.
Replicate the bug
π Note: These steps are based on the developer's analysis of the code. The exact sequence may need adjusting based on your specific version and environment. Confirm these steps against a test record before using them as a formal replication guide.
To replicate the bug:
Open a person record.
Go to Relationships and open the Add Personal Relationship dialog.
Click the Personal Relationships tab and search for a person. Open the attributes panel where you can select Carer, Emergency Contact, Next of Kin, and other attribute types.
Without saving, click the Suggested Relationships tab and open the attributes panel there too.
Select a checkbox in the Suggested Relationships attributes panel by clicking the label text, not the checkbox itself.
Check whether the selection appears in the Personal Relationships tab instead, or vice versa.
Click Save.
Check the saved record. The attributes shown may not match what you selected.
The key conditions are:
Both attribute panels must be open at the same time.
You must click the label text rather than the checkbox itself.
If you only use one tab before saving, or always click directly on the checkbox, the bug will not trigger.
Why the bug is intermittent
The bug only occurs when you have interacted with both tabs in the same session, specifically by opening the attributes panel in both, and have clicked the label text rather than the checkbox directly. Most users tend to use only one tab, which is why the bug does not trigger every time.
Risks
If the bug triggers, relationship attributes may save to the wrong relationship record without any warning. If spotted, the incorrect attributes can be corrected by editing the relationship record and updating the attributes manually.
The main risk is that the error is silent. You will not receive a warning that something has gone wrong, so you need to notice the issue by checking the saved record.
Workaround until the fix is released
You can avoid triggering this bug by clicking directly on the checkbox itself rather than the text label beside it when setting relationship attributes. This works as expected regardless of how many tabs you have opened.
Additionally, check the relationship attributes after adding any relationship to confirm they have saved correctly. If any attributes are incorrect, you can amend them manually through the worker relationships screens.
