mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2026-01-27 14:55:48 +01:00
Deal with some duplicated code, plus some collateral optimization.
This commit is contained in:
@@ -528,6 +528,8 @@ function memoize(obj, key, getter) {
|
||||
obj.__defineGetter__(key, function replace() (
|
||||
Class.replaceProperty(this.instance || this, key, null),
|
||||
Class.replaceProperty(this.instance || this, key, getter.call(this, key))));
|
||||
obj.__defineSetter__(key, function replace(val)
|
||||
Class.replaceProperty(this.instance || this, key, val));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user