Skip to content

Commit

Permalink
Merge pull request #602 from snamor/patch-1
Browse files Browse the repository at this point in the history
Add the commas to the prettified JSON
  • Loading branch information
willdurand committed Apr 14, 2015
2 parents 8b61865 + 226e388 commit ad70ff9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Resources/views/layout.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -319,7 +319,7 @@
prettifiedJsonString = prettifiedJsonString.replace(/(\{|\[)\n/g, function(match, sectionOpenCharacter) {
return getJsonCollapseHtml(sectionOpenCharacter) + '<span class="json-collapse-content">\n';
});
return prettifiedJsonString.replace(/([^\[][\}\]]),?\n/g, '$1</span>\n');
return prettifiedJsonString.replace(/([^\[][\}\]],?)\n/g, '$1</span>\n');
};
var prettifyResponse = function(text) {
Expand Down

0 comments on commit ad70ff9

Please sign in to comment.