mirror of https://github.com/go-redis/redis.git
chore: fix some comments (#2967)
Signed-off-by: kindknow <iturf@sina.com> Co-authored-by: Monkey <golang@88.com>
This commit is contained in:
parent
f5496d14dd
commit
6960bcc08d
|
@ -255,7 +255,7 @@ func NewDialer(opt *Options) func(context.Context, string, string) (net.Conn, er
|
|||
// value, leave the value blank or remove the parameter
|
||||
// - only the last value is interpreted if a parameter is given multiple times
|
||||
// - fields "network", "addr", "username" and "password" can only be set using other
|
||||
// URL attributes (scheme, host, userinfo, resp.), query paremeters using these
|
||||
// URL attributes (scheme, host, userinfo, resp.), query parameters using these
|
||||
// names will be treated as unknown parameters
|
||||
// - unknown parameter names will result in an error
|
||||
//
|
||||
|
|
|
@ -162,7 +162,7 @@ func (opt *ClusterOptions) init() {
|
|||
// value, leave the value blank or remove the parameter
|
||||
// - only the last value is interpreted if a parameter is given multiple times
|
||||
// - fields "network", "addr", "username" and "password" can only be set using other
|
||||
// URL attributes (scheme, host, userinfo, resp.), query paremeters using these
|
||||
// URL attributes (scheme, host, userinfo, resp.), query parameters using these
|
||||
// names will be treated as unknown parameters
|
||||
// - unknown parameter names will result in an error
|
||||
//
|
||||
|
|
|
@ -491,7 +491,7 @@ func (c *PubSub) getContext() context.Context {
|
|||
// Receive* APIs can not be used after channel is created.
|
||||
//
|
||||
// go-redis periodically sends ping messages to test connection health
|
||||
// and re-subscribes if ping can not not received for 1 minute.
|
||||
// and re-subscribes if ping can not received for 1 minute.
|
||||
func (c *PubSub) Channel(opts ...ChannelOption) <-chan *Message {
|
||||
c.chOnce.Do(func() {
|
||||
c.msgCh = newChannel(c, opts...)
|
||||
|
|
|
@ -469,7 +469,7 @@ var _ = Describe("Client OnConnect", func() {
|
|||
})
|
||||
})
|
||||
|
||||
var _ = Describe("Client context cancelation", func() {
|
||||
var _ = Describe("Client context cancellation", func() {
|
||||
var opt *redis.Options
|
||||
var client *redis.Client
|
||||
|
||||
|
@ -484,7 +484,7 @@ var _ = Describe("Client context cancelation", func() {
|
|||
Expect(client.Close()).NotTo(HaveOccurred())
|
||||
})
|
||||
|
||||
It("Blocking operation cancelation", func() {
|
||||
It("Blocking operation cancellation", func() {
|
||||
ctx, cancel := context.WithCancel(ctx)
|
||||
cancel()
|
||||
|
||||
|
|
Loading…
Reference in New Issue