mirror of
https://github.com/meshtastic/Meshtastic-Apple.git
synced 2026-04-20 22:13:56 +00:00
add new routing error messages
This commit is contained in:
parent
799f587314
commit
39a456954b
1 changed files with 14 additions and 0 deletions
|
|
@ -24,6 +24,8 @@ enum RoutingError: Int, CaseIterable, Identifiable {
|
|||
case notAuthorized = 33
|
||||
case pkiFailed = 34
|
||||
case pkiUnknownPubkey = 35
|
||||
case adminBadSessionKey = 36
|
||||
case adminPublicKeyUnauthorized = 37
|
||||
|
||||
var id: Int { self.rawValue }
|
||||
var display: String {
|
||||
|
|
@ -57,6 +59,10 @@ enum RoutingError: Int, CaseIterable, Identifiable {
|
|||
return "routing.pkifailed".localized
|
||||
case .pkiUnknownPubkey:
|
||||
return "routing.pkiunknownpubkey".localized
|
||||
case .adminBadSessionKey:
|
||||
return "routing.adminbadsessionkey".localized
|
||||
case .adminPublicKeyUnauthorized:
|
||||
return "routing.adminpublickeyunauthorized".localized
|
||||
}
|
||||
}
|
||||
var color: Color {
|
||||
|
|
@ -98,6 +104,10 @@ enum RoutingError: Int, CaseIterable, Identifiable {
|
|||
return true
|
||||
case .pkiUnknownPubkey:
|
||||
return true
|
||||
case .adminBadSessionKey:
|
||||
return true
|
||||
case .adminPublicKeyUnauthorized:
|
||||
return true
|
||||
}
|
||||
}
|
||||
func protoEnumValue() -> Routing.Error {
|
||||
|
|
@ -132,6 +142,10 @@ enum RoutingError: Int, CaseIterable, Identifiable {
|
|||
return Routing.Error.pkiFailed
|
||||
case .pkiUnknownPubkey:
|
||||
return Routing.Error.pkiUnknownPubkey
|
||||
case .adminBadSessionKey:
|
||||
return Routing.Error.adminBadSessionKey
|
||||
case .adminPublicKeyUnauthorized:
|
||||
return Routing.Error.adminPublicKeyUnauthorized
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue