diff --git a/backend/telemetry_core/src/state/counter.rs b/backend/telemetry_core/src/state/counter.rs index d3e12679..49ea4575 100644 --- a/backend/telemetry_core/src/state/counter.rs +++ b/backend/telemetry_core/src/state/counter.rs @@ -17,15 +17,15 @@ use crate::feed_message::Ranking; use std::collections::HashMap; -/// A data structure which counts how many occurences of a given key we've seen. +/// A data structure which counts how many occurrences of a given key we've seen. #[derive(Default)] pub struct Counter { - /// A map containing the number of occurences of a given key. + /// A map containing the number of occurrences of a given key. /// /// If there are none then the entry is removed. map: HashMap, - /// The number of occurences where the key is `None`. + /// The number of occurrences where the key is `None`. empty: u64, } @@ -39,7 +39,7 @@ impl Counter where K: Sized + std::hash::Hash + Eq, { - /// Either adds or removes a single occurence of a given `key`. + /// Either adds or removes a single occurrence of a given `key`. pub fn modify<'a, Q>(&mut self, key: Option<&'a Q>, op: CounterValue) where Q: ?Sized + std::hash::Hash + Eq, diff --git a/backend/telemetry_shard/src/json_message/hash.rs b/backend/telemetry_shard/src/json_message/hash.rs index dd647c9d..efd5a7fa 100644 --- a/backend/telemetry_shard/src/json_message/hash.rs +++ b/backend/telemetry_shard/src/json_message/hash.rs @@ -50,7 +50,7 @@ impl<'de> Visitor<'de> for HashVisitor { fn expecting(&self, formatter: &mut fmt::Formatter) -> fmt::Result { formatter.write_str( - "byte array of length 32, or hexidecimal string of 32 bytes beginning with 0x", + "byte array of length 32, or hexadecimal string of 32 bytes beginning with 0x", ) } diff --git a/backend/test_utils/src/lib.rs b/backend/test_utils/src/lib.rs index bf0de0fa..b7d3cef9 100644 --- a/backend/test_utils/src/lib.rs +++ b/backend/test_utils/src/lib.rs @@ -21,7 +21,7 @@ pub mod server; /// is the slightly-lossy inverse of the custom serialization we do to feed messages. pub mod feed_message_de; -/// A couple of macros to make it easier to test for the presense of things (mainly, feed messages) +/// A couple of macros to make it easier to test for the presence of things (mainly, feed messages) /// in an iterable container. #[macro_use] pub mod contains_matches;