ax(mining): replace prose comment on StartMiner with usage example
AX Principle 2 — comments must show HOW with real values, not restate what the signature already says. Co-Authored-By: Charon <charon@lethean.io>
This commit is contained in:
parent
32290b839b
commit
649f57e91e
1 changed files with 1 additions and 2 deletions
|
|
@ -229,8 +229,7 @@ func findAvailablePort() (int, error) {
|
|||
return listener.Addr().(*net.TCPAddr).Port, nil
|
||||
}
|
||||
|
||||
// StartMiner starts a new miner and saves its configuration.
|
||||
// The context can be used to cancel the operation.
|
||||
// miner, err := manager.StartMiner(ctx, "xmrig", &mining.Config{Algo: "rx/0"})
|
||||
func (m *Manager) StartMiner(ctx context.Context, minerType string, config *Config) (Miner, error) {
|
||||
// Check for cancellation before acquiring lock
|
||||
select {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue