1
0
mirror of https://github.com/eventials/goevents.git synced 2025-04-24 13:48:53 +08:00

Update exemple.

This commit is contained in:
Alexandre Vicenzi 2016-12-01 16:58:20 -02:00
parent 6aae479858
commit 412c735150

View File

@ -32,7 +32,7 @@ if err != nil {
panic(err)
}
c.Subscribe("my_action", func(body []byte) bool {
c.Subscribe("object.*", func(body []byte) bool {
fmt.Println(body)
return true
})
@ -53,7 +53,7 @@ if err != nil {
panic(err)
}
err = p.Publish("my_action", []byte("message"))
err = p.Publish("object.my_action", []byte("message"))
if err != nil {
panic(err)