refactor: use constant for account data prefix in setCurrentlyUsedPerMessageProfileIdForRoom

This commit is contained in:
Rye committed 2026-03-17 16:27:06 +01:00
1 parent 0ef60ca4d2
commit e321d5f953
1 file changed
+2 -2
+2 -2
View File
@@ -142,7 +142,7 @@ export function setCurrentlyUsedPerMessageProfileIdForRoom(
validUntil?: number,
reset?: boolean
) {
const accountData = mx.getAccountData(`fyi.cisnt.permessageprofile.roomassociation` as any);
const accountData = mx.getAccountData(`${ACCOUNT_DATA_PREFIX}.roomassociation` as any);
const content = accountData?.getContent();
const associations: PerMessageProfileRoomAssociation[] = Array.isArray(content) ? content : [];
@@ -156,5 +156,5 @@ export function setCurrentlyUsedPerMessageProfileIdForRoom(
const wrapper: PerMessageProfileRoomAssociationWrapper = {
associations,
};
return mx.setAccountData(`fyi.cisnt.permessageprofile.roomassociation` as any, wrapper as any);
return mx.setAccountData(`${ACCOUNT_DATA_PREFIX}.roomassociation` as any, wrapper as any);
}