You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-11-19 05:22:13 +03:00
AppTile: Test if widgetUrl startsWith instead of has a substring
The event origin should be at the beginning of the URL.
This commit is contained in:
@@ -143,7 +143,7 @@ export default React.createClass({
|
||||
event.origin = event.originalEvent.origin;
|
||||
}
|
||||
|
||||
if (this.state.widgetUrl.indexOf(event.origin) === -1) {
|
||||
if (!this.state.widgetUrl.startsWith(event.origin)) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user