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

Remove redundant DefaultDataDir call #500

Open
wants to merge 4 commits into
base: develop
Choose a base branch
from

Conversation

holisticode
Copy link

The DefaultDataDir() call is already assigned in the NodeDefaultConfig global variable on line 32 in defaults.go

Copy link
Contributor

@rus-alex rus-alex left a comment

Choose a reason for hiding this comment

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

Why don't you refactor this part totally along with it?
Existence of defaultNodeConfig() and NodeDefaultConfig at the same time is confusing. Let's replace them with single DefaultNodeConfig() for example.

@holisticode
Copy link
Author

@rus-alex refactored according to your suggestion

@@ -28,22 +29,27 @@ func overrideFlags() {
}

// NodeDefaultConfig contains reasonable default settings.
Copy link
Contributor

Choose a reason for hiding this comment

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

Godoc agreement: the comment should begins with the name of the element it describes.

Copy link
Author

Choose a reason for hiding this comment

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

Updated and also fixed tests

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.

None yet

2 participants