From 48aa02e1821f6a2c05a9d630129d137e11793a51 Mon Sep 17 00:00:00 2001 From: Thiago Kenji Okada Date: Sun, 1 Sep 2024 00:47:43 +0100 Subject: [PATCH] examples/events: close connection --- examples/events/events.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/examples/events/events.go b/examples/events/events.go index 1a2b2b4..f2befd1 100644 --- a/examples/events/events.go +++ b/examples/events/events.go @@ -20,7 +20,9 @@ func (e *ev) ActiveWindow(w event.ActiveWindow) { } func main() { - c := event.MustEventClient() + c := event.MustClient() + defer c.Close() + event.Subscribe( c, &ev{}, event.EventWorkspace,