Exit on completion
gitea/salix/pipeline/head This commit looks good
Details
gitea/salix/pipeline/head This commit looks good
Details
This commit is contained in:
parent
6f8e2c8e79
commit
726b2d5eb2
|
@ -60,7 +60,8 @@ async function test() {
|
||||||
helpers: [],
|
helpers: [],
|
||||||
});
|
});
|
||||||
|
|
||||||
jasmine.exitOnCompletion = false;
|
if (!isCI) jasmine.exitOnCompletion = false;
|
||||||
|
|
||||||
await jasmine.execute();
|
await jasmine.execute();
|
||||||
if (app) await app.disconnect();
|
if (app) await app.disconnect();
|
||||||
if (container) await container.rm();
|
if (container) await container.rm();
|
||||||
|
|
|
@ -62,8 +62,14 @@ module.exports = Self => {
|
||||||
name: fileName
|
name: fileName
|
||||||
};
|
};
|
||||||
|
|
||||||
await fs.access(file.path);
|
try {
|
||||||
let stream = fs.createReadStream(file.path);
|
await fs.access(file.path);
|
||||||
|
} catch (error) {
|
||||||
|
await Self.createPdf(ctx, id);
|
||||||
|
}
|
||||||
|
|
||||||
|
const stream = fs.createReadStream(file.path);
|
||||||
|
|
||||||
return [stream, file.contentType, `filename="${file.name}"`];
|
return [stream, file.contentType, `filename="${file.name}"`];
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
if (error.code === 'ENOENT')
|
if (error.code === 'ENOENT')
|
||||||
|
|
Loading…
Reference in New Issue