mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-22 16:18:08 +02:00
Avoid to call a function in the js sandbox when it has been destroyed
This commit is contained in:
parent
0d8828f93d
commit
4bdbf4bb3d
1 changed files with 3 additions and 0 deletions
|
@ -62,6 +62,9 @@ export class SandboxSupportBase {
|
|||
* @param {Array<Object>} args - Arguments of the function.
|
||||
*/
|
||||
callSandboxFunction(name, args) {
|
||||
if (!this.commFun) {
|
||||
return;
|
||||
}
|
||||
try {
|
||||
args = this.exportValueToSandbox(args);
|
||||
this.commFun(name, args);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue