[#411] Remove unnecessary pointers for sync objects

Signed-off-by: Alejandro Lopez <a.lopez@yadro.com>
This commit is contained in:
Alejandro Lopez 2023-05-30 10:14:37 +03:00 committed by Evgenii Stratonikov
parent f934abed8f
commit faca861451
20 changed files with 39 additions and 64 deletions

View file

@ -25,7 +25,7 @@ type Writer struct {
js nats.JetStreamContext
nc *nats.Conn
m *sync.RWMutex
m sync.RWMutex
createdStreams map[string]struct{}
opts
}
@ -84,7 +84,6 @@ func (n *Writer) Notify(topic string, address oid.Address) error {
// New creates new Writer.
func New(oo ...Option) *Writer {
w := &Writer{
m: &sync.RWMutex{},
createdStreams: make(map[string]struct{}),
opts: opts{
log: &logger.Logger{Logger: zap.L()},