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

Make appmetrics a global singleton #403

Merged
merged 2 commits into from
Mar 2, 2017
Merged

Conversation

sjanuary
Copy link
Contributor

@sjanuary sjanuary commented Mar 1, 2017

Fixes #402
@sam-github please review

@sjanuary
Copy link
Contributor Author

sjanuary commented Mar 1, 2017

CI failure looks unrelated to my PR, a new Node v7 has been released (7.7.0) and appmetrics doesn't build on it.

@sjanuary
Copy link
Contributor Author

sjanuary commented Mar 1, 2017

Looks like 7.7.0 build failure is due to nodejs/node#11628

Copy link
Contributor

@sam-github sam-github left a comment

Choose a reason for hiding this comment

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

other than the one nit, looks good

index.js Outdated
);
module.exports = global.Appmetrics;
} else {
global.Appmetrics = this;
Copy link
Contributor

Choose a reason for hiding this comment

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

global.Appmetrics = module.exports; to avoid use of this as an alias for module.exports. Its true it does that, but its not documented, may stop working, and is confusing, because its not the typical usage of this.

@tobespc tobespc merged commit 891d400 into RuntimeTools:master Mar 2, 2017
@tobespc
Copy link
Member

tobespc commented Mar 2, 2017

accepting as failing build is on the latest node7 which we don't officially support yet

@sjanuary sjanuary deleted the singleton branch March 2, 2017 11:15
@tobespc tobespc modified the milestone: 3.0 Mar 22, 2017
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