1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2026-03-07 00:45:46 +01:00

Add util.weakReference that won't crash if you pass null.

This commit is contained in:
Kris Maglione
2011-10-01 23:02:00 -04:00
parent c9583ac72f
commit 84a68bff9a
12 changed files with 25 additions and 15 deletions

View File

@@ -96,7 +96,7 @@ var Hive = Class("Hive", {
get modifiable() this.name !== "system",
addRef: function (obj) {
this.refs.push(Cu.getWeakReference(obj));
this.refs.push(util.weakReference(obj));
this.dropRef(null);
},
dropRef: function (obj) {