Skip to content

Commit

Permalink
Merge branch 'master' of github.com:mapbox/wax
Browse files Browse the repository at this point in the history
  • Loading branch information
Tom MacWright committed Mar 1, 2011
2 parents 8d18f20 + 78aae20 commit 4104c35
Show file tree
Hide file tree
Showing 6 changed files with 33 additions and 41 deletions.
4 changes: 4 additions & 0 deletions README.md
Expand Up @@ -64,6 +64,10 @@ Wax includes two libraries in `/lib` which are included in builds

## Changelog

#### 1.0.2

* Bug fixes for Firefox 3

#### 1.0.1

* `make ext` added for downloading and installing external libraries needed to use examples.
Expand Down
22 changes: 9 additions & 13 deletions build/wax.g.js
Expand Up @@ -310,7 +310,7 @@ wax.Record = function(obj, context) {
args = args.length ? wax.Record(args) : [];

// real browsers
if (!$.browser.msie) {
if (Object.create) {
obj = Object.create(fn_obj[1].prototype);
fn_obj[1].apply(obj, args);
// lord have mercy on your soul.
Expand Down Expand Up @@ -395,19 +395,15 @@ wax.Record = function(obj, context) {
case '@call':
return runFunction(statement.subject, statement.object, null);
}
} else {
// Reify object/arrays.
try {
var keys = _.keys(obj);
for (i = 0; i < keys.length; i++) {
var key = keys[i];
obj[key] = wax.Record(obj[key], context);
}
return obj;
// Unwrapped scalars
} catch(e) {
return obj;
} else if (typeof obj === 'object') {
var keys = _.keys(obj);
for (i = 0; i < keys.length; i++) {
var key = keys[i];
obj[key] = wax.Record(obj[key], context);
}
return obj;
} else {
return obj;
}
};
// Underscore.js 1.1.4
Expand Down
2 changes: 1 addition & 1 deletion build/wax.g.min.js

Large diffs are not rendered by default.

22 changes: 9 additions & 13 deletions build/wax.ol.js
Expand Up @@ -310,7 +310,7 @@ wax.Record = function(obj, context) {
args = args.length ? wax.Record(args) : [];

// real browsers
if (!$.browser.msie) {
if (Object.create) {
obj = Object.create(fn_obj[1].prototype);
fn_obj[1].apply(obj, args);
// lord have mercy on your soul.
Expand Down Expand Up @@ -395,19 +395,15 @@ wax.Record = function(obj, context) {
case '@call':
return runFunction(statement.subject, statement.object, null);
}
} else {
// Reify object/arrays.
try {
var keys = _.keys(obj);
for (i = 0; i < keys.length; i++) {
var key = keys[i];
obj[key] = wax.Record(obj[key], context);
}
return obj;
// Unwrapped scalars
} catch(e) {
return obj;
} else if (typeof obj === 'object') {
var keys = _.keys(obj);
for (i = 0; i < keys.length; i++) {
var key = keys[i];
obj[key] = wax.Record(obj[key], context);
}
return obj;
} else {
return obj;
}
};
// Underscore.js 1.1.4
Expand Down
2 changes: 1 addition & 1 deletion build/wax.ol.min.js

Large diffs are not rendered by default.

22 changes: 9 additions & 13 deletions lib/record.js
Expand Up @@ -50,7 +50,7 @@ wax.Record = function(obj, context) {
args = args.length ? wax.Record(args) : [];

// real browsers
if (!$.browser.msie) {
if (Object.create) {
obj = Object.create(fn_obj[1].prototype);
fn_obj[1].apply(obj, args);
// lord have mercy on your soul.
Expand Down Expand Up @@ -135,18 +135,14 @@ wax.Record = function(obj, context) {
case '@call':
return runFunction(statement.subject, statement.object, null);
}
} else {
// Reify object/arrays.
try {
var keys = _.keys(obj);
for (i = 0; i < keys.length; i++) {
var key = keys[i];
obj[key] = wax.Record(obj[key], context);
}
return obj;
// Unwrapped scalars
} catch(e) {
return obj;
} else if (typeof obj === 'object') {
var keys = _.keys(obj);
for (i = 0; i < keys.length; i++) {
var key = keys[i];
obj[key] = wax.Record(obj[key], context);
}
return obj;
} else {
return obj;
}
};

0 comments on commit 4104c35

Please sign in to comment.