Skip to content
This repository was archived by the owner on Nov 9, 2024. It is now read-only.

Commit 9b02e64

Browse files
authored
Merge 4c098cd into 9041f05
2 parents 9041f05 + 4c098cd commit 9b02e64

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

cmd/fs-publisher/fs-publisher.go

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,11 +56,15 @@ func main() {
5656
var notifyClient notify.Interface
5757

5858
notifyClient = new(notify.AmqpNotify)
59-
notifyClient.Init(map[string]string{
59+
err := notifyClient.Init(map[string]string{
6060
"amqp-url": c.String("amqp-url"),
6161
"exchange": c.String("amqp-exchange"),
6262
"queue": c.String("amqp-queue"),
6363
})
64+
if err != nil {
65+
return err
66+
}
67+
defer notifyClient.Close()
6468

6569
watcher := watch.FsWatcher{}
6670
watcher.Start(notifyClient, map[string]string{

0 commit comments

Comments
 (0)