From 0ddec476112952f7e43d2439f77c2e96b5a30ba2 Mon Sep 17 00:00:00 2001 From: extrawurst Date: Sat, 3 Sep 2022 10:22:24 +0200 Subject: [PATCH] cleanup --- asyncgit/src/fetch_job.rs | 14 -------------- src/ui/syntax_text.rs | 1 + 2 files changed, 1 insertion(+), 14 deletions(-) diff --git a/asyncgit/src/fetch_job.rs b/asyncgit/src/fetch_job.rs index e0d9d8ed..9859a136 100644 --- a/asyncgit/src/fetch_job.rs +++ b/asyncgit/src/fetch_job.rs @@ -36,20 +36,6 @@ impl AsyncFetchJob { )))), } } - - /// - pub fn result(&self) -> Option> { - if let Ok(mut state) = self.state.lock() { - if let Some(state) = state.take() { - return match state { - JobState::Request(_) => None, - JobState::Response(result) => Some(result), - }; - } - } - - None - } } impl AsyncJob for AsyncFetchJob { diff --git a/src/ui/syntax_text.rs b/src/ui/syntax_text.rs index ea02bdc1..6f9ac75e 100644 --- a/src/ui/syntax_text.rs +++ b/src/ui/syntax_text.rs @@ -230,6 +230,7 @@ impl AsyncSyntaxJob { } } + /// pub fn result(&self) -> Option { if let Ok(mut state) = self.state.lock() { if let Some(state) = state.take() {