mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2026-02-18 04:35:45 +01:00
Make 'doc' available to group initializer.
This commit is contained in:
@@ -611,12 +611,13 @@ function call(fn) {
|
||||
*/
|
||||
function memoize(obj, key, getter) {
|
||||
if (arguments.length == 1) {
|
||||
let res = Object.create(obj);
|
||||
for each (let prop in Object.getOwnPropertyNames(obj)) {
|
||||
let get = __lookupGetter__.call(obj, prop);
|
||||
if (get)
|
||||
memoize(obj, prop, get);
|
||||
memoize(res, prop, get);
|
||||
}
|
||||
return obj;
|
||||
return res;
|
||||
}
|
||||
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user