From ba55d8a5ad6a79d58b8a7a56d6b32f5440859d5b Mon Sep 17 00:00:00 2001 From: Rob Rix Date: Wed, 21 Oct 2015 15:50:29 -0400 Subject: [PATCH] Map deletion/insertion patches in the source diff into deletions/insertions. --- prototype/UI/index.html | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/prototype/UI/index.html b/prototype/UI/index.html index 968eb114e..9daeb8884 100644 --- a/prototype/UI/index.html +++ b/prototype/UI/index.html @@ -86,9 +86,9 @@ function patch(patch) { var before = document.getElementById("before"); var after = document.getElementById("after"); - - if (patch.delete != null) { return term(patch.delete, before); } - if (patch.insert != null) { return term(patch.insert, after); } + + if (patch.delete != null) { return Delete(term(patch.delete)); } + if (patch.insert != null) { return Insert(term(patch.insert)); } if (patch.replace != null) { if (term.patch.before != null) { term(patch.replace.before, before); } if (term.patch.after != null) { term(patch.replace.after, after); }