mirror of
https://github.com/lightningnetwork/lnd.git
synced 2024-11-20 02:27:21 +01:00
84fd911b47
Fixes new lint errors caught by the latest version.
21 lines
516 B
Go
21 lines
516 B
Go
package lncfg
|
|
|
|
import (
|
|
"fmt"
|
|
"time"
|
|
)
|
|
|
|
//nolint:lll
|
|
type Sweeper struct {
|
|
BatchWindowDuration time.Duration `long:"batchwindowduration" description:"Duration of the sweep batch window. The sweep is held back during the batch window to allow more inputs to be added and thereby lower the fee per input."`
|
|
}
|
|
|
|
// Validate checks the values configured for the sweeper.
|
|
func (s *Sweeper) Validate() error {
|
|
if s.BatchWindowDuration < 0 {
|
|
return fmt.Errorf("batchwindowduration must be positive")
|
|
}
|
|
|
|
return nil
|
|
}
|