mirror of
https://github.com/meilisearch/meilisearch.git
synced 2025-10-11 14:16:31 +00:00
Simplify MemoryStats fetching
This commit is contained in:
committed by
Louis Dureuil
parent
4de2db6786
commit
f3c34d5b8c
@@ -121,6 +121,11 @@ impl MemoryStats {
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(not(any(target_os = "linux", target_os = "macos")))]
|
||||
pub fn fetch() -> Option<Self> {
|
||||
None
|
||||
}
|
||||
|
||||
pub fn checked_sub(self, other: Self) -> Option<Self> {
|
||||
Some(Self { resident: self.resident.checked_sub(other.resident)? })
|
||||
}
|
||||
|
Reference in New Issue
Block a user