File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1040,17 +1040,23 @@ pub struct KeychainClientState {
10401040
10411041impl KeychainClientState {
10421042 pub fn new ( dsid : String , adsid : String , delegate : & MobileMeDelegateResponse ) -> Option < KeychainClientState > {
1043- Some ( KeychainClientState {
1043+ let host = delegate. config . get ( "com.apple.Dataclass.KeychainSync" ) ?. as_dictionary ( ) . unwrap ( ) . get ( "escrowProxyUrl" ) ?. as_string ( ) . unwrap ( ) . to_string ( ) ;
1044+
1045+ Some ( Self :: new_with_host ( dsid, adsid, host) )
1046+ }
1047+
1048+ pub fn new_with_host ( dsid : String , adsid : String , host : String ) -> KeychainClientState {
1049+ KeychainClientState {
10441050 dsid,
10451051 adsid,
1046- host : delegate . config . get ( "com.apple.Dataclass.KeychainSync" ) ? . as_dictionary ( ) . unwrap ( ) . get ( "escrowProxyUrl" ) ? . as_string ( ) . unwrap ( ) . to_string ( ) ,
1052+ host,
10471053 state_token : None ,
10481054 state : HashMap :: new ( ) ,
10491055 user_identity : None ,
10501056 current_bottle : None ,
10511057 keystore : KeychainKeyStore ( vec ! [ ] ) ,
10521058 items : HashMap :: new ( ) ,
1053- } )
1059+ }
10541060 }
10551061
10561062 // filter out custodian recovery keys
You can’t perform that action at this time.
0 commit comments