mirror of
https://github.com/aljazceru/ditto.git
synced 2026-01-24 07:44:28 +01:00
Push events from the client through the pipeline
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
import { Conf } from '@/config.ts';
|
||||
import { type Event, type Filter, matchFilters, RelayPool, TTLCache } from '@/deps.ts';
|
||||
import * as pipeline from '@/pipeline.ts';
|
||||
import { Time } from '@/utils.ts';
|
||||
|
||||
import type { GetFiltersOpts } from '@/types.ts';
|
||||
@@ -37,6 +38,7 @@ function getFilters<K extends number>(filters: Filter<K>[], opts: GetFiltersOpts
|
||||
Conf.poolRelays,
|
||||
(event: Event | null) => {
|
||||
if (event && matchFilters(filters, event)) {
|
||||
pipeline.handleEvent(event);
|
||||
results.push({
|
||||
id: event.id,
|
||||
kind: event.kind,
|
||||
|
||||
Reference in New Issue
Block a user