From 7375a691e232bb59033980dc09c7179bc16e377f Mon Sep 17 00:00:00 2001 From: Bruce Mitchener Date: Sun, 5 May 2024 16:41:38 +0630 Subject: Fix some typos. (#620) --- src/data/graph.rs | 2 +- src/data/pubsub.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'src/data') diff --git a/src/data/graph.rs b/src/data/graph.rs index 6a3ba15..6c701e4 100644 --- a/src/data/graph.rs +++ b/src/data/graph.rs @@ -370,7 +370,7 @@ impl Graph { // indices. let edge = self.edges.swap_remove(e.index()); let swap = match self.edges.get(e.index()) { - // no elment needed to be swapped. + // no element needed to be swapped. None => return Some(edge.weight), Some(ed) => ed.node, }; diff --git a/src/data/pubsub.rs b/src/data/pubsub.rs index 619521e..d595e03 100644 --- a/src/data/pubsub.rs +++ b/src/data/pubsub.rs @@ -103,7 +103,7 @@ impl PubSub { subscription } - /// Read the i-th message not yet read by the given subsciber. + /// Read the i-th message not yet read by the given subscriber. pub fn read_ith(&self, sub: &Subscription, i: usize) -> Option<&T> { let cursor = &self.cursors[sub.id as usize]; self.messages.get(cursor.next(self.deleted_messages) + i) -- cgit