From 57626f42cd368c86d584b9ee426c75b63f8005b5 Mon Sep 17 00:00:00 2001
From: Moul <moul@moul.re>
Date: Sun, 27 Mar 2022 10:22:24 +0200
Subject: [PATCH] [fix] #421: wot: Display information for correct identity

---
 silkaj/wot.py | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/silkaj/wot.py b/silkaj/wot.py
index 5053e102..2268e145 100644
--- a/silkaj/wot.py
+++ b/silkaj/wot.py
@@ -67,8 +67,10 @@ def received_sent_certifications(uid_pubkey):
     identity, pubkey, signed = choose_identity(uid_pubkey)
     certifications = OrderedDict()
     params = BlockchainParams().params
-    req = client(wot.requirements, pubkey)
-    req = req["identities"][0]
+    requirements = client(wot.requirements, pubkey)
+    for req in requirements["identities"]:
+        if req["pubkey"] == pubkey:
+            break
     certifications["received_expire"] = list()
     certifications["received"] = list()
     for cert in identity["others"]:
-- 
GitLab