diff options
author | toasted-nutbread <toasted-nutbread@users.noreply.github.com> | 2020-07-19 12:26:57 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-07-19 12:26:57 -0400 |
commit | e12f59f87d6d39f1a1ed5969471f4c1e6e386505 (patch) | |
tree | f1b507a08271e3a29ce4fb73bb28147749da68f5 /ext | |
parent | 71b97c20199e628618bed456e886a5ae7d9beb08 (diff) |
Force targetTabId to be null if not a number (#678)
Diffstat (limited to 'ext')
-rw-r--r-- | ext/mixed/js/comm.js | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/ext/mixed/js/comm.js b/ext/mixed/js/comm.js index 1264a33e..27cb0c34 100644 --- a/ext/mixed/js/comm.js +++ b/ext/mixed/js/comm.js @@ -221,6 +221,7 @@ class CrossFrameAPI { } async invokeTab(targetTabId, targetFrameId, action, params={}) { + if (typeof targetTabId !== 'number') { targetTabId = null; } const commPort = this._getOrCreateCommPort(targetTabId, targetFrameId); return await commPort.invoke(action, params, this._ackTimeout, this._responseTimeout); } |