We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8721565 commit d8e359aCopy full SHA for d8e359a
1 file changed
index.ts
@@ -854,16 +854,18 @@ class Applesign {
854
}
855
const ipaOut = getOutputPath(this.config.tempdir, this.config.outfile!);
856
try {
857
- fs.unlinkSync(ipaOut); // await for it
858
- } catch (e) {
859
- /* do nothing */
+ await fs.unlink(ipaOut);
+ } catch (err: any) {
+ if (err?.code !== "ENOENT") {
860
+ throw err;
861
+ }
862
863
this.events.emit("message", "Zipifying into " + ipaOut + " ...");
864
const rootFolder = this.config.payloadOnly ? "Payload" : ".";
865
await tools.zip(this.config.tempdir, ipaOut, rootFolder);
866
if (this.config.replaceipa) {
867
this.events.emit("message", "mv into " + ipaIn);
- fs.rename(ipaOut, ipaIn);
868
+ await fs.rename(ipaOut, ipaIn);
869
870
871
0 commit comments