Skip to content

Commit

Permalink
Add header callback
Browse files Browse the repository at this point in the history
  • Loading branch information
cmdcolin committed Dec 26, 2018
1 parent 7ece42f commit 9379ffe
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/JBrowse/Store/SeqFeature/BED/Parser.js
Expand Up @@ -22,6 +22,7 @@ return declare( null, {

constructor: function( args ) {
lang.mixin( this, {
headerCallback: args.headerCallback || function() {},
featureCallback: args.featureCallback || function() {},
endCallback: args.endCallback || function() {},
commentCallback: args.commentCallback || function() {},
Expand Down Expand Up @@ -52,7 +53,7 @@ return declare( null, {
continue;

// parse meta line using the parseHeader configuration callback function
var metaData = (this.parseHeader||function() {})(line);
var metaData = this.headerCallback(line);
var key = metaData.key;
headData[key] = metaData.value;
}
Expand Down

0 comments on commit 9379ffe

Please sign in to comment.