[build/dist][s]: build latest.

This commit is contained in:
Rufus Pollock
2012-10-19 08:02:34 +01:00
parent bc1c84944a
commit b93adef3d5
2 changed files with 80 additions and 15 deletions

View File

@@ -105,11 +105,12 @@ my.Dataset = Backbone.Model.extend({
}
// fields is an array of strings (i.e. list of field headings/ids)
if (fields && fields.length > 0 && typeof fields[0] === 'string') {
if (fields && fields.length > 0 && typeof(fields[0]) != 'object') {
// Rename duplicate fieldIds as each field name needs to be
// unique.
var seen = {};
fields = _.map(fields, function(field, index) {
field = field.toString();
// cannot use trim as not supported by IE7
var fieldId = field.replace(/^\s+|\s+$/g, '');
if (fieldId === '') {