chore: use owned type for DependencyType

Co-authored-by: dai <contact@daimond113.com>
This commit is contained in:
Stefan 2025-04-24 23:13:12 +01:00 committed by GitHub
parent c0a2f24fde
commit 59442c783f
Signed by: DevComp
GPG key ID: B5690EEEBB952194

View file

@ -75,8 +75,9 @@ pub enum InstallDependenciesMode {
/// Install only dev_dependencies.
Dev,
}
impl InstallDependenciesMode {
fn fits(&self, dep_ty: &DependencyType) -> bool {
fn fits(&self, dep_ty: DependencyType) -> bool {
match (self, dep_ty) {
(InstallDependenciesMode::All, _) => true,
(InstallDependenciesMode::Prod, DependencyType::Standard) => true,