MCPcopy Index your code
hub / github.com/koding/kite / renewDuration

Method renewDuration

tokenrenewer.go:111–113  ·  view source on GitHub ↗

The duration from now to the time token needs to be renewed. Needs to be calculated after renewing the token.

()

Source from the content-addressed store, hash-verified

109// The duration from now to the time token needs to be renewed.
110// Needs to be calculated after renewing the token.
111func (t *TokenRenewer) renewDuration() time.Duration {
112 return t.validUntil.Add(-renewBefore).Sub(time.Now().UTC())
113}
114
115func (t *TokenRenewer) startRenewLoop() {
116 // In case when t.client missed a disconnect signal (e.g. due to timeout observed

Callers 1

renewLoopMethod · 0.95

Calls 1

AddMethod · 0.65

Tested by

no test coverage detected