diff options
Diffstat (limited to 'crates/shirabe/src/installer/noop_installer.rs')
| -rw-r--r-- | crates/shirabe/src/installer/noop_installer.rs | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/crates/shirabe/src/installer/noop_installer.rs b/crates/shirabe/src/installer/noop_installer.rs index 95f31f2e..d36f5c9e 100644 --- a/crates/shirabe/src/installer/noop_installer.rs +++ b/crates/shirabe/src/installer/noop_installer.rs @@ -69,10 +69,10 @@ impl InstallerInterface for NoopInstaller { ) -> anyhow::Result<Option<PhpMixed>> { let mut repo = repo.borrow_mut(); if !repo.has_package(initial.clone())? { - return Err(InvalidArgumentException { - message: format!("Package is not installed: {}", initial), - code: 0, - } + return Err(InvalidArgumentException::new(format!( + "Package is not installed: {}", + initial + )) .into()); } @@ -91,10 +91,10 @@ impl InstallerInterface for NoopInstaller { ) -> anyhow::Result<Option<PhpMixed>> { let mut repo = repo.borrow_mut(); if !repo.has_package(package.clone())? { - return Err(InvalidArgumentException { - message: format!("Package is not installed: {}", package), - code: 0, - } + return Err(InvalidArgumentException::new(format!( + "Package is not installed: {}", + package + )) .into()); } repo.remove_package(package); |
