Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix Server shutdown with "Error: Can't set headers after they are sent." (close #937) #940

Merged
merged 1 commit into from
Nov 16, 2016

Conversation

LavrovArtem
Copy link
Contributor

@testcafe-build-bot
Copy link
Collaborator

❌ Tests for the commit 0415c72 have failed. See details:

Copy link
Contributor

@inikulin inikulin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

\r-

@@ -112,8 +112,11 @@ export default class DestinationRequest extends EventEmitter {
this._send();
}

else if (this._isDNSErr(err))
else if (this._isDNSErr(err)) {
this._abort();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It makes sense to refactor whole code into method:

_fatalError(msg) {
     this.aborted = true;
     this.req.abort();
     this.emit('fatalError', getText(msg, this.opts.url));
}

Remove _abort and use _fatalError everythere

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@inikulin thanks, good idea

@testcafe-build-bot
Copy link
Collaborator

❌ Tests for the commit 9202cba have failed. See details:

@testcafe-build-bot
Copy link
Collaborator

❌ Tests for the commit 44ae145 have failed. See details:

@LavrovArtem
Copy link
Contributor Author

@testcafe-build-bot \retest

@testcafe-build-bot
Copy link
Collaborator

❌ Tests for the commit 44ae145 have failed. See details:

@LavrovArtem
Copy link
Contributor Author

@testcafe-build-bot \retest

@testcafe-build-bot
Copy link
Collaborator

✅ Tests for the commit 47aa1a4 have passed. See details:

@LavrovArtem
Copy link
Contributor Author

FPR

Copy link
Contributor

@churkin churkin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@LavrovArtem
Copy link
Contributor Author

ping @inikulin

Copy link
Contributor

@inikulin inikulin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@churkin churkin merged commit 260de64 into DevExpress:master Nov 16, 2016
@LavrovArtem LavrovArtem deleted the issue-937 branch November 16, 2016 09:41
AndreyBelym pushed a commit to AndreyBelym/testcafe-hammerhead that referenced this pull request Feb 28, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants