Skip to content
This repository has been archived by the owner on Feb 26, 2024. It is now read-only.

Commit

Permalink
fix(keys): Do not use Symbol which are broken in Chrome 39.0.2171 (Da…
Browse files Browse the repository at this point in the history
…rtium)
  • Loading branch information
vicb committed Dec 11, 2015
1 parent fa18d4c commit c48301b
Showing 1 changed file with 3 additions and 10 deletions.
13 changes: 3 additions & 10 deletions lib/keys.js
Original file line number Diff line number Diff line change
@@ -1,17 +1,10 @@
/**
* Creates keys for `private` properties on exposed objects to minimize interactions with other codebases.
* The key will be a Symbol if the host supports it; otherwise a prefixed string.
*/
var create;

if (typeof Symbol === 'function') {
create = function (name) {
return Symbol(name);
}
} else {
create = function (name) {
return '_zone$' + name;
}
function create(name) {
// `Symbol` implementation is broken in Chrome 39.0.2171, do not use them even if they are available
return '_zone$' + name;
}

var commonKeys = {
Expand Down

0 comments on commit c48301b

Please sign in to comment.