From f7f34feddf26644661276e90ebd87e748d70a050 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=AB=98=E6=9C=A8=E5=90=8C=E5=AD=A6?= Date: Sun, 14 Apr 2024 22:59:09 +0800 Subject: [PATCH] Optimize docs useless imports and typo (#2970) --- README.md | 3 --- options.go | 2 +- osscluster.go | 2 +- 3 files changed, 2 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 043d3f0e6..e7df5dfd6 100644 --- a/README.md +++ b/README.md @@ -143,9 +143,6 @@ to this specification. ```go import ( - "context" - "fmt" - "github.com/redis/go-redis/v9" ) diff --git a/options.go b/options.go index d0fbdadf8..23f07bc55 100644 --- a/options.go +++ b/options.go @@ -250,7 +250,7 @@ func NewDialer(opt *Options) func(context.Context, string, string) (net.Conn, er // - field names are mapped using snake-case conversion: to set MaxRetries, use max_retries // - only scalar type fields are supported (bool, int, time.Duration) // - for time.Duration fields, values must be a valid input for time.ParseDuration(); -// additionally a plain integer as value (i.e. without unit) is intepreted as seconds +// additionally a plain integer as value (i.e. without unit) is interpreted as seconds // - to disable a duration field, use value less than or equal to 0; to use the default // value, leave the value blank or remove the parameter // - only the last value is interpreted if a parameter is given multiple times diff --git a/osscluster.go b/osscluster.go index 26261bb02..97fc9392f 100644 --- a/osscluster.go +++ b/osscluster.go @@ -157,7 +157,7 @@ func (opt *ClusterOptions) init() { // - field names are mapped using snake-case conversion: to set MaxRetries, use max_retries // - only scalar type fields are supported (bool, int, time.Duration) // - for time.Duration fields, values must be a valid input for time.ParseDuration(); -// additionally a plain integer as value (i.e. without unit) is intepreted as seconds +// additionally a plain integer as value (i.e. without unit) is interpreted as seconds // - to disable a duration field, use value less than or equal to 0; to use the default // value, leave the value blank or remove the parameter // - only the last value is interpreted if a parameter is given multiple times