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

lib: rewrite i-face introspection without promises #245

Closed
wants to merge 1 commit into from

Conversation

tshemsedinov
Copy link
Member

No description provided.

@tshemsedinov tshemsedinov requested a review from aqrln June 28, 2017 16:26
@tshemsedinov tshemsedinov changed the title Rewrite interface introspection without Promises lib: rewrite interface introspection without promises Jun 28, 2017
let errored = false;
const len = interfaces.length;
let cnt = 0;
interfaces.map(name => connection.inspectInterface(name,
Copy link
Member

Choose a reason for hiding this comment

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

What's the point of using a map method here, if the result is being ignored in the end?
Maybe replace it with forEach?

reject(error);
} else {
resolve(proxy);
const proxies = {};
Copy link
Member

Choose a reason for hiding this comment

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

This object should be created with Object.create(null) like it was done before this patch.

Copy link
Member Author

Choose a reason for hiding this comment

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

@belochub yes, it's better, thanks

@tshemsedinov tshemsedinov force-pushed the use-callbacks-luke branch 2 times, most recently from 67639cb to 3d9e87c Compare June 28, 2017 22:50
@belochub
Copy link
Member

belochub commented Jul 6, 2017

Name and commit message of this PR exceed the 50 character limit, it should be renamed.

const proxies = Object.create(null);
let errored = false;
const len = interfaces.length;
let cnt = 0;
Copy link
Member

Choose a reason for hiding this comment

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

In my opinion, it is better to rename this variable to full name (count) to avoid possible misunderstanding.

Copy link
Member

@aqrln aqrln left a comment

Choose a reason for hiding this comment

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

LGTM pending @belochub's comment.

Copy link
Member

@lundibundi lundibundi left a comment

Choose a reason for hiding this comment

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

LGTM after adressing @belochub comments.

@tshemsedinov
Copy link
Member Author

@belochub agree, fixed, who will merge?

@belochub belochub changed the title lib: rewrite interface introspection without promises lib: rewrite i-face introspection without promises Jul 7, 2017
Copy link
Member

@belochub belochub left a comment

Choose a reason for hiding this comment

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

LGTM

belochub pushed a commit that referenced this pull request Jul 7, 2017
PR-URL: #245
Reviewed-By: Alexey Orlenko <eaglexrlnk@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Mykola Bilochub <nbelochub@gmail.com>
@belochub
Copy link
Member

belochub commented Jul 7, 2017

Landed in 43c61e7.

@belochub belochub closed this Jul 7, 2017
@belochub belochub deleted the use-callbacks-luke branch July 7, 2017 15:13
belochub pushed a commit that referenced this pull request Jan 22, 2018
PR-URL: #245
Reviewed-By: Alexey Orlenko <eaglexrlnk@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Mykola Bilochub <nbelochub@gmail.com>
belochub pushed a commit that referenced this pull request Jan 22, 2018
PR-URL: #245
Reviewed-By: Alexey Orlenko <eaglexrlnk@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Mykola Bilochub <nbelochub@gmail.com>
@belochub belochub mentioned this pull request Jan 22, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants