mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2024-12-29 09:22:22 -05:00
Only set src attribute if it’s not empty
window.Image does not support clearing the attribute by setting it to null
This commit is contained in:
parent
de36f39cbf
commit
9cafb6d55f
1 changed files with 2 additions and 1 deletions
|
@ -408,6 +408,7 @@ var Raster = Item.extend(/** @lends Raster# */{
|
|||
crossOrigin = this._crossOrigin;
|
||||
if (crossOrigin)
|
||||
image.crossOrigin = crossOrigin;
|
||||
if (src)
|
||||
image.src = src;
|
||||
this.setImage(image);
|
||||
},
|
||||
|
|
Loading…
Reference in a new issue