You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-11-07 10:46:24 +03:00
Change argument order of setRoomWidget
So when deleting a widget we can just omit the ones we don't need
This commit is contained in:
@@ -210,7 +210,7 @@ export default class WidgetUtils {
|
||||
console.error(`$widgetId is non-configurable`);
|
||||
}
|
||||
|
||||
const addingWidget = widgetUrl !== null;
|
||||
const addingWidget = Boolean(widgetUrl);
|
||||
|
||||
// Add new widget / update
|
||||
if (addingWidget) {
|
||||
@@ -234,10 +234,10 @@ export default class WidgetUtils {
|
||||
});
|
||||
}
|
||||
|
||||
static setRoomWidget(widgetId, widgetType, widgetUrl, widgetName, widgetData, roomId) {
|
||||
static setRoomWidget(roomId, widgetId, widgetType, widgetUrl, widgetName, widgetData) {
|
||||
let content;
|
||||
|
||||
const addingWidget = widgetUrl !== null;
|
||||
const addingWidget = Boolean(widgetUrl);
|
||||
|
||||
if (addingWidget) {
|
||||
content = {
|
||||
|
||||
Reference in New Issue
Block a user