From ba97aa7ad2343d712c86f03673816d75bedb2cbd Mon Sep 17 00:00:00 2001 From: ansuz Date: Tue, 24 Oct 2017 18:09:38 +0200 Subject: [PATCH] allow file upload handler to create thumbnails for whiteboard --- www/whiteboard/inner.js | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/www/whiteboard/inner.js b/www/whiteboard/inner.js index e71b7fe69..626ad1a90 100644 --- a/www/whiteboard/inner.js +++ b/www/whiteboard/inner.js @@ -238,17 +238,9 @@ define([ APP.upload = function (title) { var canvas = $canvas[0]; APP.canvas.deactivateAll().renderAll(); - var finish = function (thumb) { - canvas.toBlob(function (blob) { - blob.name = title; - APP.FM.handleFile(blob, void 0, thumb); - }); - }; - - Thumb.fromCanvas(canvas, function (e, blob) { - // carry on even if you can't get a thumbnail - if (e) { console.error(e); } - finish(blob); + canvas.toBlob(function (blob) { + blob.name = title; + APP.FM.handleFile(blob); }); };