diff options
author | uvok cheetah | 2023-12-08 17:10:14 +0000 |
---|---|---|
committer | uvok cheetah | 2023-12-08 17:10:14 +0000 |
commit | 16f43836594f2400e52d21da61b6dd32feca9b7d (patch) | |
tree | a80ad31e00cbda8eabdba5fb7e1799dc444eb25f /nats/notify.go | |
parent | 4e44a6606351e76a52719945548a14df4de8f3f6 (diff) |
Move NATS server URL into struct
Diffstat (limited to 'nats/notify.go')
-rw-r--r-- | nats/notify.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/nats/notify.go b/nats/notify.go index 56cbc7f..d75928d 100644 --- a/nats/notify.go +++ b/nats/notify.go @@ -6,10 +6,11 @@ import ( ) type NatsNotifier struct { + ServerUrl string } func (notif *NatsNotifier) NotifyNewRegistration(reg *registration.Registration) error { - conn, err := nats.Connect("nats://nats-server:4222") + conn, err := nats.Connect(notif.ServerUrl) if err != nil { return err } |