kopia lustrzana https://github.com/c9/core
Merge pull request #512 from DanielDiBe/headers-sent-fix
Fix issue #496: Cannot set headers after they are sent to the clientpull/518/head
commit
cc906be318
|
@ -138,6 +138,7 @@ function plugin(options, imports, register) {
|
||||||
req.on("close", function() {
|
req.on("close", function() {
|
||||||
done = true;
|
done = true;
|
||||||
cancel();
|
cancel();
|
||||||
|
if(!res.headersSent)
|
||||||
res.json({}, 0, 500);
|
res.json({}, 0, 500);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
Ładowanie…
Reference in New Issue