Loading system/gd/rust/common/src/sys_prop.rs +1 −1 Original line number Original line Diff line number Diff line Loading @@ -3,7 +3,7 @@ /// Gets the value of a system property on Android /// Gets the value of a system property on Android #[cfg(target_os = "android")] #[cfg(target_os = "android")] pub fn get(name: &str) -> Option<String> { pub fn get(name: &str) -> Option<String> { rustutils::system_properties::read(name).ok() rustutils::system_properties::read(name).unwrap_or(None) } } /// Fake getter for non-Android, which will always return nothing. /// Fake getter for non-Android, which will always return nothing. Loading Loading
system/gd/rust/common/src/sys_prop.rs +1 −1 Original line number Original line Diff line number Diff line Loading @@ -3,7 +3,7 @@ /// Gets the value of a system property on Android /// Gets the value of a system property on Android #[cfg(target_os = "android")] #[cfg(target_os = "android")] pub fn get(name: &str) -> Option<String> { pub fn get(name: &str) -> Option<String> { rustutils::system_properties::read(name).ok() rustutils::system_properties::read(name).unwrap_or(None) } } /// Fake getter for non-Android, which will always return nothing. /// Fake getter for non-Android, which will always return nothing. Loading