Skip to content

Commit

Permalink
refactor(index): swap negated condition
Browse files Browse the repository at this point in the history
  • Loading branch information
Fdawgs committed Feb 22, 2024
1 parent d2e21d6 commit ee06254
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -244,9 +244,7 @@ class UnRTF {
/* istanbul ignore else */
if (stdOut !== "") {
resolve(stdOut.trim());
} else if (stdErr !== "") {
reject(new Error(stdErr.trim()));
} else {
} else if (stdErr === "") {
reject(
new Error(
errorMessages[code] ||
Expand All @@ -255,6 +253,8 @@ class UnRTF {
)} exited with code ${code}`
)
);
} else {
reject(new Error(stdErr.trim()));
}
});
});
Expand Down

0 comments on commit ee06254

Please sign in to comment.