diff options
Diffstat (limited to 'pkg/commands/publish.go')
| -rw-r--r-- | pkg/commands/publish.go | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/pkg/commands/publish.go b/pkg/commands/publish.go new file mode 100644 index 0000000..5959d57 --- /dev/null +++ b/pkg/commands/publish.go @@ -0,0 +1,12 @@ +package commands + +import ( + "net" + "redisClone/pkg/pubsub" +) + +func Publish(hub *pubsub.Hub, conn net.Conn, args []string) interface{}{ + channel := args[1] + msg := args[2] + return hub.Publish(channel, msg) +}
\ No newline at end of file |
