mirror of
https://github.com/turt2live/matrix-dimension.git
synced 2024-10-01 01:05:53 -04:00
Always send a request_id to Riot
Fixes https://github.com/turt2live/matrix-dimension/issues/241 Cherry picked from 17eb46e48d3bd40a76579735966eff3fd535e479
This commit is contained in:
parent
06ceecc05c
commit
005b471dc7
@ -2,6 +2,7 @@ import { ScalarToWidgetRequest } from "../../models/scalar-widget-actions";
|
|||||||
import { ReplaySubject } from "rxjs/ReplaySubject";
|
import { ReplaySubject } from "rxjs/ReplaySubject";
|
||||||
import { Subject } from "rxjs/Subject";
|
import { Subject } from "rxjs/Subject";
|
||||||
import { FE_Sticker, FE_StickerPack } from "../../models/integration";
|
import { FE_Sticker, FE_StickerPack } from "../../models/integration";
|
||||||
|
import * as randomString from "random-string";
|
||||||
|
|
||||||
export class ScalarWidgetApi {
|
export class ScalarWidgetApi {
|
||||||
|
|
||||||
@ -89,6 +90,7 @@ export class ScalarWidgetApi {
|
|||||||
request["api"] = "fromWidget";
|
request["api"] = "fromWidget";
|
||||||
request["widgetId"] = ScalarWidgetApi.widgetId;
|
request["widgetId"] = ScalarWidgetApi.widgetId;
|
||||||
request["action"] = action;
|
request["action"] = action;
|
||||||
|
request["requestId"] = randomString({length: 160});
|
||||||
|
|
||||||
window.opener.postMessage(request, "*");
|
window.opener.postMessage(request, "*");
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user