From 9e69e2aed163352e7551317ae97f6a17b695b694 Mon Sep 17 00:00:00 2001 From: Pavel Ivanov Date: Sun, 26 Nov 2023 12:18:16 +0100 Subject: [PATCH] fix: some typos and linter warnings fixed --- Cargo.lock | 2 +- Cargo.toml | 2 +- src/index.rs | 6 +++--- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 23a0c5a5..64c6fea0 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -728,7 +728,7 @@ checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" [[package]] name = "hl" -version = "0.20.0" +version = "0.20.1-alpha.1" dependencies = [ "atoi", "bincode", diff --git a/Cargo.toml b/Cargo.toml index 5657152e..af7dac92 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -4,7 +4,7 @@ categories = ["command-line-utilities"] description = "Utility for viewing json-formatted log files." keywords = ["cli", "human", "log"] name = "hl" -version = "0.20.0" +version = "0.20.1-alpha.1" edition = "2021" build = "build.rs" diff --git a/src/index.rs b/src/index.rs index 44ab8983..da403426 100644 --- a/src/index.rs +++ b/src/index.rs @@ -248,7 +248,7 @@ impl Indexer { scope.spawn(closure!(ref sfi, |_| { for segment in rxi.iter() { let ((stat, chronology), segment) = match segment { - Segment::Complete(segment) => (self.process_segement(&segment), segment), + Segment::Complete(segment) => (self.process_segment(&segment), segment), Segment::Incomplete(segment, _) => { let mut stat = Stat::new(); stat.add_invalid(); @@ -304,7 +304,7 @@ impl Indexer { .unwrap() } - fn process_segement(&self, segment: &SegmentBuf) -> (Stat, Chronology) { + fn process_segment(&self, segment: &SegmentBuf) -> (Stat, Chronology) { let mut stat = Stat::new(); let mut sorted = true; let mut prev_ts = None; @@ -441,7 +441,7 @@ impl Index { let ts = index.get_timestamps(); let flags = index.get_flags(); Stat { - flags: flags, + flags, lines_valid: lines.get_valid(), lines_invalid: lines.get_invalid(), ts_min_max: if flags & schema::FLAG_HAS_TIMESTAMPS != 0 {