mirror of
https://github.com/signalapp/Signal-Desktop.git
synced 2025-12-20 02:08:57 +00:00
Highlight that dataURLToBlob is synchronous
This commit is contained in:
@@ -104,7 +104,7 @@
|
||||
i = i - 1;
|
||||
// TODO: Replace with native `Canvas::toBlob`:
|
||||
// https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/toBlob
|
||||
blob = window.dataURLToBlob(
|
||||
blob = window.dataURLToBlobSync(
|
||||
canvas.toDataURL('image/jpeg', quality)
|
||||
);
|
||||
quality = quality * maxSize / blob.size;
|
||||
@@ -233,7 +233,7 @@
|
||||
|
||||
// TODO: Replace with native `Canvas::toBlob`:
|
||||
// https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/toBlob
|
||||
var blob = window.dataURLToBlob(canvas.toDataURL('image/png'));
|
||||
var blob = window.dataURLToBlobSync(canvas.toDataURL('image/png'));
|
||||
|
||||
resolve(blob);
|
||||
};
|
||||
|
||||
@@ -60,7 +60,7 @@
|
||||
window.nodeSetImmediate(function() {});
|
||||
}, 1000);
|
||||
|
||||
window.dataURLToBlob = require('blueimp-canvas-to-blob');
|
||||
window.dataURLToBlobSync = require('blueimp-canvas-to-blob');
|
||||
window.loadImage = require('blueimp-load-image');
|
||||
window.ProxyAgent = require('proxy-agent');
|
||||
window.EmojiConvertor = require('emoji-js');
|
||||
|
||||
Reference in New Issue
Block a user