mirror of
https://github.com/yuezk/GlobalProtect-openconnect.git
synced 2025-05-20 07:26:58 -04:00
Refactor using Tauri (#278)
This commit is contained in:
6
crates/gpapi/src/utils/xml.rs
Normal file
6
crates/gpapi/src/utils/xml.rs
Normal file
@@ -0,0 +1,6 @@
|
||||
use roxmltree::Document;
|
||||
|
||||
pub(crate) fn get_child_text(doc: &Document, name: &str) -> Option<String> {
|
||||
let node = doc.descendants().find(|n| n.has_tag_name(name))?;
|
||||
node.text().map(|s| s.to_string())
|
||||
}
|
Reference in New Issue
Block a user