Commit 56d732f9 authored by Brian Tiger Chow's avatar Brian Tiger Chow

fix(2/main) s/preemptsUpdates/preemptsAutoUpdate

addresses...

https://github.com/jbenet/go-ipfs/pull/336#discussion_r20397834

License: MIT
Signed-off-by: default avatarBrian Tiger Chow <brian@perfmode.com>
parent 408fadc8
......@@ -61,7 +61,7 @@ type cmdDetails struct {
// command
initializesConfig bool
preemptsUpdates bool
preemptsAutoUpdate bool
}
func (d *cmdDetails) String() string {
......@@ -84,8 +84,8 @@ var cmdDetailsMap = map[*cmds.Command]cmdDetails{
commands.CommandsDaemonCmd: cmdDetails{doesNotUseRepo: true},
commands.DiagCmd: cmdDetails{cannotRunOnClient: true},
commands.VersionCmd: cmdDetails{doesNotUseRepo: true},
commands.UpdateCmd: cmdDetails{preemptsUpdates: true, cannotRunOnDaemon: true},
commands.UpdateCheckCmd: cmdDetails{preemptsUpdates: true},
commands.UpdateLogCmd: cmdDetails{preemptsUpdates: true},
commands.UpdateCmd: cmdDetails{preemptsAutoUpdate: true, cannotRunOnDaemon: true},
commands.UpdateCheckCmd: cmdDetails{preemptsAutoUpdate: true},
commands.UpdateLogCmd: cmdDetails{preemptsAutoUpdate: true},
commands.LogCmd: cmdDetails{cannotRunOnClient: true},
}
......@@ -215,7 +215,7 @@ func callPreCommandHooks(details cmdDetails, req cmds.Request, root *cmds.Comman
// check for updates when 1) commands is going to be run locally, 2) the
// command does not initialize the config, and 3) the command does not
// pre-empt updates
if !daemon && !details.initializesConfig && !details.preemptsUpdates {
if !daemon && !details.initializesConfig && !details.preemptsAutoUpdate {
log.Debug("Calling hook: Check for updates")
......
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