diff --git a/lib/Viewer.js b/lib/Viewer.js index 8cb894b9..beea89cc 100644 --- a/lib/Viewer.js +++ b/lib/Viewer.js @@ -12,7 +12,7 @@ function getSvgContents(diagram) { var outerNode = diagram.get('canvas').getContainer(); var svg = outerNode.innerHTML; - return svg.replace(/.*]*>|<\/svg>.*$/g, '') + return svg.replace(/^.*]*>|<\/svg>.*$/g, '') .replace('Created with Snap', '') .replace(/')).toBe(-1); + expect(svg.indexOf('')).toBe(-1); - expect(svg.indexOf('