Merge pull request #1803 from paulkaplan/remove-promise-finally

Remove promise finally because we are having trouble with polyfills
This commit is contained in:
Paul Kaplan 2018-12-04 13:01:34 -05:00 committed by GitHub
commit 051e2f5014
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -121,6 +121,10 @@ const fetchBitmapCanvas_ = function (costume, runtime, rotationCenter) {
}
costume.bitmapResolution = 2;
// Clean up the costume object
delete costume.textLayerMD5;
delete costume.textLayerAsset;
return {
canvas: canvas,
rotationCenter: rotationCenter,
@ -128,8 +132,8 @@ const fetchBitmapCanvas_ = function (costume, runtime, rotationCenter) {
assetMatchesBase: scale === 1 && !textImageElement
};
})
.finally(() => {
// Clean up the costume object
.catch(() => {
// Clean up the text layer properties if it fails to load
delete costume.textLayerMD5;
delete costume.textLayerAsset;
});