Language: JavaScript
Label: vulnerable
CWE: CWE-79 \u2014 Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.

Code:
this.insertHandler(J,null,null,O.defaultVertexStyle,O.defaultEdgeStyle,!1,!0)}finally{O.model.endUpdate()}}}catch(Y){if(z)throw Y;this.handleError(Y)}return J};EditorUi.prototype.updatePageLinks=function(d,f){for(var k=0;k<f.length;k++)this.updatePageLinksForCell(d,f[k].root),null!=f[k].viewState&&this.updateBackgroundPageLink(d,f[k].viewState.backgroundImage)};EditorUi.prototype.updateBackgroundPageLink=function(d,f){try{if(null!=f&&Graph.isPageLink(f.originalSrc)){var k=d[f.originalSrc.substring(f.originalSrc.indexOf(",")+
1)];null!=k&&(f.originalSrc="data:page/id,"+k)}}catch(v){}};EditorUi.prototype.updatePageLinksForCell=function(d,f){var k=document.createElement("div"),v=this.editor.graph,z=v.getLinkForCell(f);null!=z&&v.setLinkForCell(f,this.updatePageLink(d,z));if(v.isHtmlLabel(f)){k.innerHTML=Graph.sanitizeHtml(v.getLabel(f));for(var A=k.getElementsByTagName("a"),H=!1,J=0;J<A.length;J++)z=A[J].getAttribute("href"),null!=z&&(A[J].setAttribute("href",this.updatePageLink(d,z)),H=!0);H&&v.labelChanged(f,k.innerHTML)}for(J=