This commit is contained in:
+6
-8
@@ -25,7 +25,7 @@ pub trait Slime {
|
||||
}
|
||||
}
|
||||
|
||||
fn print_from_values(&self, values: &Vec<String>) {
|
||||
fn print_from_values(&self, values: &[String]) {
|
||||
for (i, val) in values.iter().enumerate() {
|
||||
if i == 0 {
|
||||
print!(
|
||||
@@ -42,7 +42,7 @@ pub trait Slime {
|
||||
}
|
||||
|
||||
pub fn get_all_slimes() -> Vec<Box<dyn Slime>> {
|
||||
let mut slimes: Vec<Box<dyn Slime>> = vec![
|
||||
let slimes: Vec<Box<dyn Slime>> = vec![
|
||||
Box::new(OsSlime),
|
||||
Box::new(KernelSlime),
|
||||
Box::new(HostnameSlime),
|
||||
@@ -51,14 +51,12 @@ pub fn get_all_slimes() -> Vec<Box<dyn Slime>> {
|
||||
Box::new(GpuSlime),
|
||||
Box::new(RamSlime),
|
||||
Box::new(NetworkSlime),
|
||||
#[cfg(feature = "monitors")]
|
||||
Box::new(MonitorSlime),
|
||||
#[cfg(feature = "audio")]
|
||||
Box::new(AudioSlime),
|
||||
];
|
||||
|
||||
#[cfg(feature = "monitors")]
|
||||
slimes.push(Box::new(MonitorSlime));
|
||||
|
||||
#[cfg(feature = "audio")]
|
||||
slimes.push(Box::new(AudioSlime));
|
||||
|
||||
slimes
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user