1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2025-02-02 12:19:11 +00:00

Fix diff-text widget crash with empty/missing attributes

Fixes #7462
This commit is contained in:
jeremy@jermolene.com 2023-05-18 12:47:40 +01:00
parent a4da53ef6c
commit 8ad08b0cd4

View File

@ -39,7 +39,7 @@ DiffTextWidget.prototype.render = function(parent,nextSibling) {
this.execute(); this.execute();
// Create the diff // Create the diff
var dmpObject = new dmp.diff_match_patch(), var dmpObject = new dmp.diff_match_patch(),
diffs = dmpObject.diff_main(this.getAttribute("source"),this.getAttribute("dest")); diffs = dmpObject.diff_main(this.getAttribute("source",""),this.getAttribute("dest",""));
// Apply required cleanup // Apply required cleanup
switch(this.getAttribute("cleanup","semantic")) { switch(this.getAttribute("cleanup","semantic")) {
case "none": case "none":