825: Fixed a pubsub mutability inconsistency r=lulf a=diondokter

All other publish methods don't require mut

Co-authored-by: Dion Dokter <diondokter@gmail.com>
This commit is contained in:
bors[bot] 2022-06-22 13:09:47 +00:00 committed by GitHub
commit e3a13a05be
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -108,7 +108,7 @@ impl<'a, PSB: PubSubBehavior<T> + ?Sized, T: Clone> ImmediatePub<'a, PSB, T> {
}
/// Publish the message right now even when the queue is full.
/// This may cause a subscriber to miss an older message.
pub fn publish_immediate(&mut self, message: T) {
pub fn publish_immediate(&self, message: T) {
self.channel.publish_immediate(message)
}