Skip to content

Commit

Permalink
fix: Remove unneccesary locking in in-memory broker for sending to wo…
Browse files Browse the repository at this point in the history
…rk channel.
  • Loading branch information
iamd3vil committed Mar 14, 2024
1 parent b2e1026 commit 6d3cbc4
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions brokers/in-memory/broker.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,7 @@ func (r *Broker) Consume(ctx context.Context, work chan []byte, queue string) {
r.pending[queue] = r.pending[queue][1:]
r.pmu.Unlock()

r.mu.RLock()
work <- d
r.mu.RUnlock()
}
}
}
Expand Down

0 comments on commit 6d3cbc4

Please sign in to comment.