diff options
author | Moonchild <wolfbeast@users.noreply.github.com> | 2016-10-15 11:27:38 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-10-15 11:27:38 +0200 |
commit | 8c437c45e93e47ed4bfec3b6b1dc7b5df7da8eb8 (patch) | |
tree | 9dbff85985f25ed28d2012fe95850993e32c5aa7 | |
parent | 162adf29a1328667908007f60d865242169c8c3f (diff) | |
parent | 06273e0bcd9ccc117bfab78d6849cca6a4de84c4 (diff) | |
download | palemoon-gre-8c437c45e93e47ed4bfec3b6b1dc7b5df7da8eb8.tar.gz |
Merge pull request #600 from janekptacijarabaci/minorFix_async_objectCreateVs__proto__
Minor fix: Async (Object.create vs. __proto__)
-rw-r--r-- | services/common/async.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/services/common/async.js b/services/common/async.js index e0070380b..5bdfc8a54 100644 --- a/services/common/async.js +++ b/services/common/async.js @@ -194,9 +194,9 @@ this.Async = { querySpinningly: function querySpinningly(query, names) { // 'Synchronously' asyncExecute, fetching all results by name. - let storageCallback = {names: names, - syncCb: Async.makeSyncCallback()}; - storageCallback.__proto__ = Async._storageCallbackPrototype; + let storageCallback = Object.create(Async._storageCallbackPrototype); + storageCallback.names = names; + storageCallback.syncCb = Async.makeSyncCallback(); query.executeAsync(storageCallback); return Async.waitForSyncCallback(storageCallback.syncCb); }, |