mirror of
https://github.com/rustfs/rustfs.git
synced 2026-08-05 21:07:43 +00:00
tmp
This commit is contained in:
@@ -109,6 +109,16 @@ impl Endpoints {
|
||||
pub fn into_inner(self) -> Vec<Endpoint> {
|
||||
self.0
|
||||
}
|
||||
|
||||
// GetString - returns endpoint string of i-th endpoint (0-based),
|
||||
// and empty string for invalid indexes.
|
||||
pub fn get_string(&self, i: usize) -> String {
|
||||
if i < 0 || i >= self.0.len() {
|
||||
return "".to_string();
|
||||
}
|
||||
|
||||
self.0[i].to_string()
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Debug)]
|
||||
|
||||
Reference in New Issue
Block a user