Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 3f3962f

Browse files
esbenaerik-krogh
andauthored
Update javascript/ql/src/Security/CWE-730/examples/server-crash.GOOD-B.js
Co-authored-by: Erik Krogh Kristensen <[email protected]>
1 parent 718f6eb commit 3f3962f

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

javascript/ql/src/Security/CWE-730/examples/server-crash.GOOD-B.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// ...
22
express().post("/save", async (req, res) => {
3-
if (await fs.promises.exists(rootDir)) {
3+
if (!(await fs.promises.exists(rootDir))) {
44
console.error(`Server setup is corrupted, ${rootDir} does not exist!`);
55
res.status(500);
66
res.end();

0 commit comments

Comments
 (0)