@@ -975,12 +975,8 @@ async def send_read_data_agreement_message(self, connection_record: ConnectionRe
975
975
pairwise_local_did_record .verkey , key_type = KeyType .ED25519 )
976
976
977
977
# to_did
978
- pairwise_remote_did_record = await storage .search_records (
979
- type_filter = ConnectionManager .RECORD_TYPE_DID_KEY ,
980
- tag_query = {"did" : connection_record .their_did }
981
- ).fetch_single ()
982
978
to_did = DIDMyData .from_public_key_b58 (
983
- pairwise_remote_did_record . value , key_type = KeyType .ED25519 )
979
+ connection_record . their_did , key_type = KeyType .ED25519 )
984
980
except StorageError as err :
985
981
raise ADAManagerError (
986
982
f"Failed to send read-data-agreement message: { err } "
@@ -2569,12 +2565,8 @@ async def construct_data_agreement_negotiation_accept_message(self, *, data_agre
2569
2565
pairwise_local_did_record .verkey , key_type = KeyType .ED25519 )
2570
2566
2571
2567
# to_did
2572
- pairwise_remote_did_record = await storage .search_records (
2573
- type_filter = ConnectionManager .RECORD_TYPE_DID_KEY ,
2574
- tag_query = {"did" : connection_record .their_did }
2575
- ).fetch_single ()
2576
2568
to_did = DIDMyData .from_public_key_b58 (
2577
- pairwise_remote_did_record . value , key_type = KeyType .ED25519 )
2569
+ connection_record . their_did , key_type = KeyType .ED25519 )
2578
2570
except StorageError as err :
2579
2571
raise ADAManagerError (
2580
2572
f"Failed to construct data agreement negotiation accept message: { err } "
@@ -2679,12 +2671,8 @@ async def construct_data_agreement_negotiation_reject_message(self, *, data_agr
2679
2671
pairwise_local_did_record .verkey , key_type = KeyType .ED25519 )
2680
2672
2681
2673
# to_did
2682
- pairwise_remote_did_record = await storage .search_records (
2683
- type_filter = ConnectionManager .RECORD_TYPE_DID_KEY ,
2684
- tag_query = {"did" : connection_record .their_did }
2685
- ).fetch_single ()
2686
2674
to_did = DIDMyData .from_public_key_b58 (
2687
- pairwise_remote_did_record . value , key_type = KeyType .ED25519 )
2675
+ connection_record . their_did , key_type = KeyType .ED25519 )
2688
2676
except StorageError as err :
2689
2677
raise ADAManagerError (
2690
2678
f"Failed to construct data agreement negotiation accept message: { err } "
@@ -2791,12 +2779,8 @@ async def construct_data_agreement_negotiation_problem_report_message(self, *, c
2791
2779
pairwise_local_did_record .verkey , key_type = KeyType .ED25519 )
2792
2780
2793
2781
# to_did
2794
- pairwise_remote_did_record = await storage .search_records (
2795
- type_filter = ConnectionManager .RECORD_TYPE_DID_KEY ,
2796
- tag_query = {"did" : connection_record .their_did }
2797
- ).fetch_single ()
2798
2782
to_did = DIDMyData .from_public_key_b58 (
2799
- pairwise_remote_did_record . value , key_type = KeyType .ED25519 )
2783
+ connection_record . their_did , key_type = KeyType .ED25519 )
2800
2784
except StorageError as err :
2801
2785
raise ADAManagerError (
2802
2786
f"Failed to construct data agreement negotiation problem-report message: { err } "
@@ -2861,12 +2845,8 @@ async def construct_data_agreement_termination_terminate_message(self, *, data_
2861
2845
pairwise_local_did_record .verkey , key_type = KeyType .ED25519 )
2862
2846
2863
2847
# to_did
2864
- pairwise_remote_did_record = await storage .search_records (
2865
- type_filter = ConnectionManager .RECORD_TYPE_DID_KEY ,
2866
- tag_query = {"did" : connection_record .their_did }
2867
- ).fetch_single ()
2868
2848
to_did = DIDMyData .from_public_key_b58 (
2869
- pairwise_remote_did_record . value , key_type = KeyType .ED25519 )
2849
+ connection_record . their_did , key_type = KeyType .ED25519 )
2870
2850
except StorageError as err :
2871
2851
raise ADAManagerError (
2872
2852
f"Failed to construct data agreement termination terminate message: { err } "
0 commit comments