Skip to content

Commit 3c66462

Browse files
committed
typo
Signed-off-by: Sergey Shepelev <temotor@gmail.com>
1 parent 54767d4 commit 3c66462

File tree

5 files changed

+10
-10
lines changed

5 files changed

+10
-10
lines changed

client.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ type Client interface {
5858
// IsConnected returns a bool signifying whether
5959
// the client is connected or not.
6060
IsConnected() bool
61-
// IsConnectionOpen return a bool signifying wether the client has an active
61+
// IsConnectionOpen return a bool signifying whether the client has an active
6262
// connection to mqtt broker, i.e not in disconnected or reconnect mode
6363
IsConnectionOpen() bool
6464
// Connect will create a connection to the message broker, by default

filestore.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ func (store *FileStore) Get(key string) packets.ControlPacket {
124124
}
125125

126126
// All will provide a list of all of the keys associated with messages
127-
// currenly residing in the FileStore.
127+
// currently residing in the FileStore.
128128
func (store *FileStore) All() []string {
129129
store.RLock()
130130
defer store.RUnlock()

options.go

+6-6
Original file line numberDiff line numberDiff line change
@@ -149,23 +149,23 @@ func (o *ClientOptions) SetResumeSubs(resume bool) *ClientOptions {
149149

150150
// SetClientID will set the client id to be used by this client when
151151
// connecting to the MQTT broker. According to the MQTT v3.1 specification,
152-
// a client id mus be no longer than 23 characters.
152+
// a client id must be no longer than 23 characters.
153153
func (o *ClientOptions) SetClientID(id string) *ClientOptions {
154154
o.ClientID = id
155155
return o
156156
}
157157

158158
// SetUsername will set the username to be used by this client when connecting
159159
// to the MQTT broker. Note: without the use of SSL/TLS, this information will
160-
// be sent in plaintext accross the wire.
160+
// be sent in plaintext across the wire.
161161
func (o *ClientOptions) SetUsername(u string) *ClientOptions {
162162
o.Username = u
163163
return o
164164
}
165165

166166
// SetPassword will set the password to be used by this client when connecting
167167
// to the MQTT broker. Note: without the use of SSL/TLS, this information will
168-
// be sent in plaintext accross the wire.
168+
// be sent in plaintext across the wire.
169169
func (o *ClientOptions) SetPassword(p string) *ClientOptions {
170170
o.Password = p
171171
return o
@@ -174,7 +174,7 @@ func (o *ClientOptions) SetPassword(p string) *ClientOptions {
174174
// SetCredentialsProvider will set a method to be called by this client when
175175
// connecting to the MQTT broker that provide the current username and password.
176176
// Note: without the use of SSL/TLS, this information will be sent
177-
// in plaintext accross the wire.
177+
// in plaintext across the wire.
178178
func (o *ClientOptions) SetCredentialsProvider(p CredentialsProvider) *ClientOptions {
179179
o.CredentialsProvider = p
180180
return o
@@ -301,7 +301,7 @@ func (o *ClientOptions) SetWriteTimeout(t time.Duration) *ClientOptions {
301301
}
302302

303303
// SetConnectTimeout limits how long the client will wait when trying to open a connection
304-
// to an MQTT server before timeing out and erroring the attempt. A duration of 0 never times out.
304+
// to an MQTT server before timing out and erroring the attempt. A duration of 0 never times out.
305305
// Default 30 seconds. Currently only operational on TCP/TLS connections.
306306
func (o *ClientOptions) SetConnectTimeout(t time.Duration) *ClientOptions {
307307
o.ConnectTimeout = t
@@ -324,7 +324,7 @@ func (o *ClientOptions) SetAutoReconnect(a bool) *ClientOptions {
324324
}
325325

326326
// SetMessageChannelDepth sets the size of the internal queue that holds messages while the
327-
// client is temporairily offline, allowing the application to publish when the client is
327+
// client is temporarily offline, allowing the application to publish when the client is
328328
// reconnecting. This setting is only valid if AutoReconnect is set to true, it is otherwise
329329
// ignored.
330330
func (o *ClientOptions) SetMessageChannelDepth(s uint) *ClientOptions {

token.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ type ConnectToken struct {
125125
sessionPresent bool
126126
}
127127

128-
// ReturnCode returns the acknowlegement code in the connack sent
128+
// ReturnCode returns the acknowledgement code in the connack sent
129129
// in response to a Connect()
130130
func (c *ConnectToken) ReturnCode() byte {
131131
c.m.RLock()

topic.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ var ErrInvalidTopicMultilevel = errors.New("Invalid Topic; multi-level wildcard
4646
// - A TopicName may not contain a wildcard.
4747
// - A TopicFilter may only have a # (multi-level) wildcard as the last level.
4848
// - A TopicFilter may contain any number of + (single-level) wildcards.
49-
// - A TopicFilter with a # will match the absense of a level
49+
// - A TopicFilter with a # will match the absence of a level
5050
// Example: a subscription to "foo/#" will match messages published to "foo".
5151

5252
func validateSubscribeMap(subs map[string]byte) ([]string, []byte, error) {

0 commit comments

Comments
 (0)