chore: remove recursive

This commit is contained in:
sidwebworks
2025-08-04 23:31:17 +05:30
parent c8108ff49a
commit fc772e6b89
4 changed files with 4 additions and 7 deletions
@@ -13,11 +13,9 @@ const AUTH_REFRESH_INTERVAL = 60 * 1000;
const HEART_BEAT_INTERVAL = 15 * 1000;
export const sseServiceFactory = (bus: TEventBusService, redis: Redis) => {
let heartbeatInterval: NodeJS.Timeout | null = null;
const clients = new Set<EventStreamClient>();
heartbeatInterval = setInterval(() => {
const heartbeatInterval = setInterval(() => {
for (const client of clients) {
if (client.stream.closed) continue;
void client.ping();
@@ -78,7 +78,7 @@ export function createEventStreamClient(redis: Redis, options: IEventStreamClien
...(hasConditions
? {
environment: r.conditions?.environmentSlug ?? "",
secretPath: r.conditions?.recursive ? { $glob: `${secretPath}/**` } : secretPath
secretPath: { $glob: secretPath }
}
: {})
}
+1 -2
View File
@@ -117,8 +117,7 @@ export const EventRegisterSchema = z.object({
conditions: z
.object({
secretPath: z.string().optional().default("/"),
environmentSlug: z.string(),
recursive: z.boolean().optional().default(false)
environmentSlug: z.string()
})
.optional()
});