Skip to content

Commit

Permalink
fixed wrong error case
Browse files Browse the repository at this point in the history
  • Loading branch information
cpietsch committed May 1, 2023
1 parent 6a972da commit 50081c7
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/textures.js
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,11 @@ exports.run = async function textures(inputPath, options) {
let spritesheetFiles = [];
for await (const operation of resizer) {
console.log(operation.progress, operation.file);
if (operation.log[2]) spritesheetFiles.push(operation.log[2]);
else console.error("Error with file", operation.file);
if (!skipTextures && operation.log[2]) {
spritesheetFiles.push(operation.log[2]);
} else if (skipTextures && operation.log[0]) {
spritesheetFiles.push(operation.log[0]);
} else console.error("Error with file", operation.file);
}

if (multipe) {
Expand Down

0 comments on commit 50081c7

Please sign in to comment.