Skip to content

Commit 3277783

Browse files
authored
Make global-bind plugin safe in node envs, part 2
Follow on from #465, which missed the ReferenceError from trying to use the Mousetrap global at the end of the file.
1 parent 56c7959 commit 3277783

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: plugins/global-bind/mousetrap-global-bind.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -43,4 +43,4 @@
4343
};
4444

4545
Mousetrap.init();
46-
}) (Mousetrap);
46+
}) (typeof Mousetrap !== "undefined" ? Mousetrap : undefined);

0 commit comments

Comments
 (0)