Skip to content

Commit

Permalink
Minor fixes in comments
Browse files Browse the repository at this point in the history
* Fix typo

"netowrk" is a misspelling of "network"

* Fix export comment

Comment on exported type Hub should be of the form "Hub ..." (golint)
  • Loading branch information
chebyrash authored and garyburd committed Apr 16, 2018
1 parent eb92580 commit cd94665
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion examples/chat/hub.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

package main

// hub maintains the set of active clients and broadcasts messages to the
// Hub maintains the set of active clients and broadcasts messages to the
// clients.
type Hub struct {
// Registered clients.
Expand Down
2 changes: 1 addition & 1 deletion proxy.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import (
"strings"
)

type netDialerFunc func(netowrk, addr string) (net.Conn, error)
type netDialerFunc func(network, addr string) (net.Conn, error)

func (fn netDialerFunc) Dial(network, addr string) (net.Conn, error) {
return fn(network, addr)
Expand Down

1 comment on commit cd94665

@thethinking
Copy link

@thethinking thethinking commented on cd94665 May 29, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi, friend!
Actually I have a question about the line 44#-49# of hub.go. I would just write it as client.send <- message to send message to each client. What the purpose to code like this?

Please sign in to comment.