mirror of
https://github.com/rclone/rclone.git
synced 2024-12-23 07:29:35 +01:00
mailru: use variable type int instead of time.Duration for keeping number of seconds
Fixes problem reported by staticcheck lint tool (v0.3.2): Poorly chosen name for variable of type time.Duration (ST1011).
This commit is contained in:
parent
0f41e91d41
commit
5006ede266
@ -2277,7 +2277,7 @@ type serverPool struct {
|
||||
pool pendingServerMap
|
||||
mu sync.Mutex
|
||||
path string
|
||||
expirySec time.Duration
|
||||
expirySec int
|
||||
fs *Fs
|
||||
}
|
||||
|
||||
@ -2384,7 +2384,7 @@ func (p *serverPool) addServer(url string, now time.Time) {
|
||||
p.mu.Lock()
|
||||
defer p.mu.Unlock()
|
||||
|
||||
expiry := now.Add(p.expirySec * time.Second)
|
||||
expiry := now.Add(time.Duration(p.expirySec) * time.Second)
|
||||
|
||||
expiryStr := []byte("-")
|
||||
if p.fs.ci.LogLevel >= fs.LogLevelInfo {
|
||||
|
Loading…
Reference in New Issue
Block a user