fix: fetch results
Some checks failed
continuous-integration/drone/push Build is failing

This commit is contained in:
kieran 2024-06-18 10:09:41 +01:00
parent 64a34e43f0
commit 44435db21d
Signed by: Kieran
GPG Key ID: DE71CEB3925BE941
2 changed files with 2 additions and 2 deletions

View File

@ -76,7 +76,7 @@ export class QueryManager extends EventEmitter<QueryManagerEvents> {
* Async fetch results
*/
async fetch(req: RequestBuilder, cb?: (evs: Array<TaggedNostrEvent>) => void) {
const filters = req.buildRaw();
const filters = req.buildRaw(this.#system);
const q = this.query(req);
if (cb) {
q.on("event", cb);

View File

@ -113,7 +113,7 @@ export class RequestBuilder {
if (!this.#rawCached && system) {
this.#rawCached = system.optimizer.compress(this.#builders.map(f => f.filter));
}
return this.#rawCached ?? [];
return this.#rawCached ?? this.#builders.map(f => f.filter);
}
build(system: SystemInterface): Array<BuiltRawReqFilter> {