AppTile: Test if widgetUrl startsWith instead of has a substring

The event origin should be at the beginning of the URL.
pull/21833/head
Robert Swain 2017-09-25 17:14:25 +02:00
parent 6e49926228
commit 24de01e21d
1 changed files with 1 additions and 1 deletions

View File

@ -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;
}