Skip to content

Conversation

@KristianDD
Copy link
Contributor

PR Checklist

What is the current behavior?

What is the new behavior?

Fixes/Implements/Closes #[Issue Number].

@KristianDD KristianDD force-pushed the kddimitrov/fix-two-fast-consecutive-syncs branch from 5c41250 to ccfa6d2 Compare August 1, 2018 07:25
if (this.socketConnection && this.socketConnection.uid === socketId) {
this.end();
this.socketError = error;
this.end(error);
Copy link
Contributor

@Fatme Fatme Aug 1, 2018

Choose a reason for hiding this comment

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

Why do we need to pass error here as parameter? We can use it directly in end() function

public end() {
const error = this.socketError || this.getErrorWithMessage()
}

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It is a personal preference. If someone moves this.socketError = error one line down or the error is not cleared at the right moment, the method might be broken without us noticing.

@KristianDD
Copy link
Contributor Author

run ci

1 similar comment
@KristianDD
Copy link
Contributor Author

run ci

@KristianDD KristianDD merged commit 3e70b85 into release Aug 1, 2018
@KristianDD KristianDD deleted the kddimitrov/fix-two-fast-consecutive-syncs branch August 1, 2018 12:04
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.

3 participants