Skip to content

Commit

Permalink
a little more robustness when dealing with malformed data
Browse files Browse the repository at this point in the history
  • Loading branch information
rbuels committed Jun 13, 2012
1 parent 6c0b7cd commit c0a4cca
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions js/SeqFeatureStore/NCList.js
Expand Up @@ -37,7 +37,7 @@ SeqFeatureStore.NCList.prototype.load = function() {
// fetch the trackdata
dojo.xhrGet({ url: url,
handleAs: "json",
load: dojo.hitch( this, function(o) { this.loadSuccess(o, url); }),
load: Util.debugHandler( this, function(o) { this.loadSuccess(o, url); }),
error: dojo.hitch( this, function(e) { console.error(''+e); this.loadFail(e, url); } )
});
};
Expand All @@ -50,7 +50,7 @@ SeqFeatureStore.NCList.prototype.loadSuccess = function( trackInfo, url ) {

this.loadNCList( trackInfo, url );

if (trackInfo.histograms) {
if ( trackInfo.histograms && trackInfo.histograms.meta ) {
this.histograms = trackInfo.histograms;
for (var i = 0; i < this.histograms.meta.length; i++) {
this.histograms.meta[i].lazyArray =
Expand Down

0 comments on commit c0a4cca

Please sign in to comment.