diff --git a/src/ui/heat_map.js b/src/ui/heat_map.js index 03778faab0aa32fe777255ea6517dadd14c4a871..37029244d4dd00a91e83bf4936ade88588e89ef8 100644 --- a/src/ui/heat_map.js +++ b/src/ui/heat_map.js @@ -2925,8 +2925,12 @@ morpheus.HeatMap.prototype = { var context = canvas.getContext('2d'); this.snapshot(context); canvas.toBlob(function (blob) { - if (blob.size === 0) { - throw 'Image is too large.'; + if (blob == null || blob.size === 0) { + morpheus.FormBuilder.showInModal({ + title: 'Save Image', + html: 'Image is too large to save.' + }); + return; } saveAs(blob, file, true);