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.ui.pages.push(this.ui.createPage());0>mxUtils.indexOf(this.ui.pages,this.ui.currentPage)&&this.ui.selectPage(this.ui.pages[0],!0)}finally{K.container.style.visibility="";K.model.endUpdate();K.cellRenderer.redraw=R;this.changeListenerEnabled=S;g||(y.history=q,y.indexOfNextAdd=E,y.fireEvent(new mxEventObject(mxEvent.CLEAR)));if(null==this.ui.currentPage||this.ui.currentPage.needsUpdate)L!=K.mathEnabled?(this.ui.editor.updateGraphComponents(),K.refresh()):(G!=K.foldingEnabled?K.view.revalidate():
K.view.validate(),K.sizeDidChange());null!=this.sync&&this.isRealtime()&&!n&&(this.sync.snapshot=this.ui.clonePages(this.ui.pages));this.ui.editor.fireEvent(new mxEventObject("pagesPatched","patches",b))}EditorUi.debug("DrawioFile.patch",[this],"patches",b,"resolver",e,"undoable",g)}return b};