Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

Commit

Permalink
Ensure that widget PersistedElement IDs are unique between rooms
Browse files Browse the repository at this point in the history
Signed-off-by: Robin Townsend <robin@robin.town>
  • Loading branch information
robintown committed Mar 12, 2022
1 parent 14807de commit 4402158
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/components/views/elements/AppTile.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,11 @@ export default class AppTile extends React.Component<IProps, IState> {
AppTile.addLiveTile(this.props.app.id);

// The key used for PersistedElement
this.persistKey = getPersistKey(this.props.app.id);
this.persistKey = getPersistKey(
this.props.room ?
`room_${this.props.room.roomId}_${this.props.app.id}` :
`user_${this.props.app.id}`,
);
try {
this.sgWidget = new StopGapWidget(this.props);
this.setupSgListeners();
Expand Down

0 comments on commit 4402158

Please sign in to comment.