1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2025-12-20 04:07:59 +01:00

Fix harmless error when document is unloaded immediately after exiting hint mode.

This commit is contained in:
Kris Maglione
2013-04-21 19:57:28 -07:00
parent 61cf89c929
commit fe998eca06

View File

@@ -490,6 +490,10 @@ var HintSession = Class("HintSession", CommandMode, {
let n = 5; let n = 5;
(function next() { (function next() {
if (Cu.isDeadWrapper && Cu.isDeadWrapper(elem))
// Hint document has been unloaded.
return;
let hinted = n || this.validHints.some(function (h) h.elem === elem); let hinted = n || this.validHints.some(function (h) h.elem === elem);
if (!hinted) if (!hinted)
hints.setClass(elem, null); hints.setClass(elem, null);