Skip to content

Commit

Permalink
If an additional parser is added after @markup in a comment block, @m…
Browse files Browse the repository at this point in the history
…arkup lumps it together. Added in a check to fix this.
  • Loading branch information
pearlchen-old committed Dec 28, 2013
1 parent 7fd92ea commit 0b0eaa4
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion dss.js
Expand Up @@ -384,7 +384,12 @@ dss.parser('state', function(i, line, block, file){

// Describe parsing markup
dss.parser('markup', function(i, line, block, file){
var markup = block.split('').splice(i, block.length).join('');

// find the next instance of a parser (if there is one based on the @ symbol)
// in order to isolate the current multi-line parser
var nextParserIndex = block.indexOf('* @', i+1),
markupLength = nextParserIndex > -1 ? nextParserIndex - i : block.length,
markup = block.split('').splice(i, markupLength).join('');

markup = (function(markup){
var ret = [];
Expand Down

0 comments on commit 0b0eaa4

Please sign in to comment.