Skip to content

Commit

Permalink
fix: psd空组
Browse files Browse the repository at this point in the history
  • Loading branch information
army8735 committed Jan 2, 2025
1 parent c8b17e2 commit ba0affe
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/format/psd.ts
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,10 @@ async function convertItem(layer: Layer, w: number, h: number) {
const innerShadow: string[] = [];
const innerShadowEnable: boolean[] = [];
const canvasPromise = new Promise<JLayer | undefined>(resolve => {
canvas!.toBlob(blob => {
if (!canvas) {
return resolve(undefined);
}
canvas.toBlob(blob => {
if (blob) {
return resolve({
tagName: TAG_NAME.BITMAP,
Expand Down

0 comments on commit ba0affe

Please sign in to comment.