Skip to content

Commit

Permalink
Merge pull request #6991 from samme/fix/v4.0.0/addBase64-key-conflict
Browse files Browse the repository at this point in the history
Fail gracefully when a texture isn't created in `addBase64()`
  • Loading branch information
photonstorm authored Jan 2, 2025
2 parents 8b9d8fb + d226b2c commit 23969f0
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/textures/TextureManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -383,6 +383,11 @@ var TextureManager = new Class({
{
var texture = _this.create(key, image);

if (!texture)
{
return;
}

Parser.Image(texture, 0);

_this.emit(Events.ADD, key, texture);
Expand Down

0 comments on commit 23969f0

Please sign in to comment.