Commit c883f7dc authored by Brian Tiger Chow's avatar Brian Tiger Chow Committed by Juan Batiz-Benet

refactor(2/init) extract const

License: MIT
Signed-off-by: default avatarBrian Tiger Chow <brian@perfmode.com>

# TYPES
# feat
# fix
# docs
# style (formatting, missing semi colons, etc; no code change):
# refactor
# test (adding missing tests, refactoring tests; no production code change)
# chore (updating grunt tasks etc; no production code change)
Signed-off-by: default avatarBrian Tiger Chow <brian.holderchow@gmail.com>
parent 81f5d6fd
......@@ -19,6 +19,8 @@ import (
errors "github.com/jbenet/go-ipfs/util/errors"
)
const nBitsForKeypairDefault = 4096
var initCmd = &cmds.Command{
Helptext: cmds.HelpText{
Tagline: "Initializes IPFS config file",
......@@ -53,7 +55,7 @@ var initCmd = &cmds.Command{
return nil, err
}
if !bitsOptFound {
nBitsForKeypair = 4096
nBitsForKeypair = nBitsForKeypairDefault
}
return doInit(req.Context().ConfigRoot, dspathOverride, force, nBitsForKeypair)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment