Remove unnecessary cache copying in ratelimiting

Signed-off-by: Wendi Yu <wendi.yu@yahoo.ca>
This commit is contained in:
Wendi Yu
2020-05-08 10:16:43 -06:00
parent 8a94ccc5a2
commit ac5039ab39
2 changed files with 3 additions and 14 deletions

View File

@@ -196,12 +196,12 @@ func newNode(t *testing.T, prefix string, https *httptest.Server, weirdPrefs boo
logfe := func(fmt string, args ...interface{}) {
t.Logf(prefix+".e: "+fmt, args...)
}
logfe := logger.RateLimitedFn(logfe, 1, 1)
logfe = logger.RateLimitedFn(logfe, 1, 1, 100)
logf := func(fmt string, args ...interface{}) {
t.Logf(prefix+": "+fmt, args...)
}
logf := logger.RateLimitedFn(logf, 1, 1, 100)
logf = logger.RateLimitedFn(logf, 1, 1, 100)
var err error
httpc := https.Client()