An easy-to-host PDS on the ATProtocol, iPhone and MacOS. Maintain control of your keys and data, always.
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

fix(identity-wallet/pds_client): fix borrow-after-move in XRPC error paths

Save resp.status() before consuming resp with .text().await to avoid
borrow-after-move compilation errors in all three XRPC functions.

authored by

Malpercio and committed by
Tangled
548fbdd2 da743b60

+6 -6
+6 -6
apps/identity-wallet/src-tauri/src/pds_client.rs
··· 557 557 message: format!("request_plc_operation_signature failed: {}", e), 558 558 })?; 559 559 560 - if resp.status().is_success() { 560 + let status = resp.status(); 561 + if status.is_success() { 561 562 Ok(()) 562 563 } else { 563 - let status = resp.status(); 564 564 let body = resp.text().await.unwrap_or_default(); 565 565 Err(PdsClientError::NetworkError { 566 566 message: format!("request_plc_operation_signature returned {}: {}", status, body), ··· 580 580 message: format!("sign_plc_operation failed: {}", e), 581 581 })?; 582 582 583 - if !resp.status().is_success() { 584 - let status = resp.status(); 583 + let status = resp.status(); 584 + if !status.is_success() { 585 585 let body = resp.text().await.unwrap_or_default(); 586 586 return Err(PdsClientError::NetworkError { 587 587 message: format!("sign_plc_operation returned {}: {}", status, body), ··· 606 606 message: format!("get_recommended_did_credentials failed: {}", e), 607 607 })?; 608 608 609 - if !resp.status().is_success() { 610 - let status = resp.status(); 609 + let status = resp.status(); 610 + if !status.is_success() { 611 611 let body = resp.text().await.unwrap_or_default(); 612 612 return Err(PdsClientError::NetworkError { 613 613 message: format!("get_recommended_did_credentials returned {}: {}", status, body),