Add device locked error type

This commit is contained in:
Jackson Coxson
2025-04-30 08:40:59 -06:00
parent 388aaef42e
commit 6090507e75

View File

@@ -423,6 +423,10 @@ pub enum IdeviceError {
#[error("user denied pairing trust")]
UserDeniedPairing,
#[cfg(feature = "pair")]
#[error("device is locked")]
PasswordProtected,
#[cfg(feature = "misagent")]
#[error("misagent operation failed")]
MisagentFailure,
@@ -510,6 +514,8 @@ impl IdeviceError {
"PairingDialogResponsePending" => Some(Self::PairingDialogResponsePending),
#[cfg(feature = "pair")]
"UserDeniedPairing" => Some(Self::UserDeniedPairing),
#[cfg(feature = "pair")]
"PasswordProtected" => Some(Self::PasswordProtected),
"InternalError" => {
let detailed_error = context
.get("DetailedError")