Skip to content

Commit

Permalink
Merge branch 'jharting-apiparam-allowed-type-line-break'
Browse files Browse the repository at this point in the history
  • Loading branch information
rottmann committed Jan 13, 2017
2 parents 31f17cd + 79032e8 commit 714e598
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions lib/parsers/api_param.js
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,13 @@ function parse(content, source, defaultGroup) {
if ( ! matches)
return null;

// reverse Unicode Linebreaks
matches.forEach(function (val, index, array) {
if (val) {
array[index] = val.replace(/\uffff/g, '\n');
}
});

var allowedValues = matches[4];
if (allowedValues) {
var regExp;
Expand All @@ -98,10 +105,6 @@ function parse(content, source, defaultGroup) {
allowedValues = list;
}

// Replace Unicode Linebreaks in description
if (matches[10])
matches[10] = matches[10].replace(/\uffff/g, '\n');

// Set global group variable
group = matches[1] || defaultGroup || 'Parameter';

Expand Down

0 comments on commit 714e598

Please sign in to comment.