Get a human-readable description.
(&self)
| 77 | impl IdentityUsage { |
| 78 | /// Get a human-readable description. |
| 79 | pub fn description(&self) -> String { |
| 80 | match self { |
| 81 | IdentityUsage::Personal => "Personal".to_string(), |
| 82 | IdentityUsage::Work => "Work".to_string(), |
| 83 | IdentityUsage::Community => "Community".to_string(), |
| 84 | IdentityUsage::Bot => "Bot".to_string(), |
| 85 | IdentityUsage::Custom(name) => format!("Custom: {}", name), |
| 86 | } |
| 87 | } |
| 88 | |
| 89 | /// Get a short code for compact display. |
| 90 | pub fn short_code(&self) -> &str { |