Cleaner presentation of patches
This commit is contained in:
parent
7f785008c8
commit
cd754be396
|
@ -223,9 +223,9 @@ Patch.prototype.projectObjects = function (compiledProjection) {
|
|||
};
|
||||
|
||||
Patch.prototype.pretty = function () {
|
||||
return ("<<<<<<<< Removed:\n" + Trie.prettyTrie(this.removed) + "\n" +
|
||||
"======== Added:\n" + Trie.prettyTrie(this.added) + "\n" +
|
||||
">>>>>>>>");
|
||||
return ("\n" +
|
||||
"-" + Trie.prettyTrie(this.removed, { lineSep: "\n-" }) + "\n" +
|
||||
"+" + Trie.prettyTrie(this.added, { lineSep: "\n+" }) + "\n");
|
||||
};
|
||||
|
||||
// Completely ignores success-values in t.
|
||||
|
|
|
@ -837,7 +837,7 @@ function prettyTrie(m, optionsOpt) {
|
|||
.sortBy(function (k, key) { return key })
|
||||
.forEach(function (k, key) {
|
||||
if (needSep) {
|
||||
acc.push("\n");
|
||||
acc.push(options.lineSep || "\n");
|
||||
acc.push(indentStr(i));
|
||||
} else {
|
||||
needSep = true;
|
||||
|
|
Loading…
Reference in New Issue