Skip to content

Commit

Permalink
Fixed empty layers in .pixi file opening
Browse files Browse the repository at this point in the history
  • Loading branch information
flabbet committed Jan 6, 2021
1 parent dd6f54b commit 323b4bb
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion PixiEditor/Models/ImageManipulation/BitmapUtils.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,10 @@ public static class BitmapUtils
public static WriteableBitmap BytesToWriteableBitmap(int currentBitmapWidth, int currentBitmapHeight, byte[] byteArray)
{
WriteableBitmap bitmap = BitmapFactory.New(currentBitmapWidth, currentBitmapHeight);
bitmap.FromByteArray(byteArray);
if (byteArray != null)
{
bitmap.FromByteArray(byteArray);
}
return bitmap;
}

Expand Down

0 comments on commit 323b4bb

Please sign in to comment.