aboutsummaryrefslogtreecommitdiffstats
path: root/tools/thread-cache-test.js
diff options
context:
space:
mode:
Diffstat (limited to 'tools/thread-cache-test.js')
-rw-r--r--tools/thread-cache-test.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/tools/thread-cache-test.js b/tools/thread-cache-test.js
index e8b0ccf..6bac353 100644
--- a/tools/thread-cache-test.js
+++ b/tools/thread-cache-test.js
@@ -84,7 +84,8 @@ try {
const { messagesFeature } = await import(path);
let requests = [], waiting = [];
globalThis.__threadQuery = (filter) => {
- if (filter.kinds?.includes(1) && (filter.ids || filter['#e'])) {
+ // root lookups by id carry no kind (a root can be a poll); reply queries are kind 1
+ if (filter.ids || (filter.kinds?.includes(1) && filter['#e'])) {
requests.push(filter);
return new Promise((resolve) => waiting.push({ filter, resolve }));
}