Author: batosai
Date: 2008-08-14 21:04:55 +0000 (Thu, 14 Aug 2008)
New Revision: 21870
Modified:
trunk/apps/WoT/src/plugins/WoT/WoT.java
Log:
Drop the identity if its in no trust tree anymore.
Modified: trunk/apps/WoT/src/plugins/WoT/WoT.java
===================================================================
--- trunk/apps/WoT/src/plugins/WoT/WoT.java 2008-08-14 20:47:48 UTC (rev
21869)
+++ trunk/apps/WoT/src/plugins/WoT/WoT.java 2008-08-14 21:04:55 UTC (rev
21870)
@@ -130,7 +130,15 @@
if(newRank == -1) { // None of the trusters had capacity in
that trust tree, this identity isn't either
try {
score = identity.getScore(treeOwner, db);
- db.delete(score); // We get this identity out
of the trust tree
+ db.delete(score); // We get this identity out
of this trust tree
+
+ // Check if this identity still is in one trust
tree
+ if(db.queryByExample(new
Score(null,identity,0,0,0)).size() == 0) {
+ db.delete(identity); // Drop it from
database
+ // TODO Stop its persistent requests
+ }
+
+
}catch (NotInTrustTreeException e) {
// Nothing to do
}