Skip to content

Commit c8d61b4

Browse files
committed
[BDAP] Do not filter expired domain entries in get function
1 parent 800dd20 commit c8d61b4

File tree

1 file changed

+4
-14
lines changed

1 file changed

+4
-14
lines changed

src/bdap/domainentrydb.cpp

+4-14
Original file line numberDiff line numberDiff line change
@@ -21,27 +21,17 @@ CDomainEntryDB *pDomainEntryDB = NULL;
2121

2222
bool GetDomainEntry(const std::vector<unsigned char>& vchObjectPath, CDomainEntry& entry)
2323
{
24-
if (!pDomainEntryDB || !pDomainEntryDB->ReadDomainEntry(vchObjectPath, entry)) {
24+
if (!pDomainEntryDB || !pDomainEntryDB->ReadDomainEntry(vchObjectPath, entry))
2525
return false;
26-
}
27-
28-
if (chainActive.Tip() && (unsigned int)chainActive.Tip()->GetMedianTimePast() >= entry.nExpireTime) {
29-
entry.SetNull();
30-
return false;
31-
}
26+
3227
return !entry.IsNull();
3328
}
3429

3530
bool GetDomainEntryPubKey(const std::vector<unsigned char>& vchPubKey, CDomainEntry& entry)
3631
{
37-
if (!pDomainEntryDB || !pDomainEntryDB->ReadDomainEntryPubKey(vchPubKey, entry)) {
32+
if (!pDomainEntryDB || !pDomainEntryDB->ReadDomainEntryPubKey(vchPubKey, entry))
3833
return false;
39-
}
40-
41-
if ((unsigned int)chainActive.Tip()->GetMedianTimePast() >= entry.nExpireTime) {
42-
entry.SetNull();
43-
return false;
44-
}
34+
4535
return !entry.IsNull();
4636
}
4737

0 commit comments

Comments
 (0)