From a1c7e6908a26e10f6e1f23a51721664b5e2d838d Mon Sep 17 00:00:00 2001 From: nsfisis Date: Sun, 17 May 2026 02:53:53 +0900 Subject: chore(style): cargo fmt --- crates/shirabe/src/util/loop.rs | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) (limited to 'crates/shirabe/src/util/loop.rs') diff --git a/crates/shirabe/src/util/loop.rs b/crates/shirabe/src/util/loop.rs index 41e1f25..189b8a3 100644 --- a/crates/shirabe/src/util/loop.rs +++ b/crates/shirabe/src/util/loop.rs @@ -1,12 +1,12 @@ //! ref: composer/src/Composer/Util/Loop.php +use crate::util::http_downloader::HttpDownloader; +use crate::util::process_executor::ProcessExecutor; use anyhow::Result; use indexmap::IndexMap; -use shirabe_php_shim::microtime; use shirabe_external_packages::react::promise::promise_interface::PromiseInterface; use shirabe_external_packages::symfony::component::console::helper::progress_bar::ProgressBar; -use crate::util::http_downloader::HttpDownloader; -use crate::util::process_executor::ProcessExecutor; +use shirabe_php_shim::microtime; #[derive(Debug)] pub struct Loop { @@ -17,7 +17,10 @@ pub struct Loop { } impl Loop { - pub fn new(mut http_downloader: HttpDownloader, process_executor: Option) -> Self { + pub fn new( + mut http_downloader: HttpDownloader, + process_executor: Option, + ) -> Self { http_downloader.enable_async(); let process_executor = process_executor.map(|mut pe| { @@ -41,7 +44,11 @@ impl Loop { self.process_executor.as_ref() } - pub fn wait(&mut self, promises: Vec>, progress: Option<&mut ProgressBar>) -> Result<()> { + pub fn wait( + &mut self, + promises: Vec>, + progress: Option<&mut ProgressBar>, + ) -> Result<()> { let mut uncaught: Option = None; shirabe_external_packages::react::promise::all(&promises).then( -- cgit v1.3.1