chore: undeclared versions/updates (#19649)

This commit is contained in:
Min Idzelis 2025-06-30 23:23:41 -04:00 committed by GitHub
parent a5c431fbf5
commit db0415bbcc
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
11 changed files with 477 additions and 282 deletions

View file

@ -1,6 +1,6 @@
import { Injectable } from '@nestjs/common';
import archiver from 'archiver';
import chokidar, { WatchOptions } from 'chokidar';
import chokidar, { ChokidarOptions } from 'chokidar';
import { escapePath, glob, globStream } from 'fast-glob';
import { constants, createReadStream, createWriteStream, existsSync, mkdirSync } from 'node:fs';
import fs from 'node:fs/promises';
@ -219,14 +219,14 @@ export class StorageRepository {
}
}
watch(paths: string[], options: WatchOptions, events: Partial<WatchEvents>) {
watch(paths: string[], options: ChokidarOptions, events: Partial<WatchEvents>) {
const watcher = chokidar.watch(paths, options);
watcher.on('ready', () => events.onReady?.());
watcher.on('add', (path) => events.onAdd?.(path));
watcher.on('change', (path) => events.onChange?.(path));
watcher.on('unlink', (path) => events.onUnlink?.(path));
watcher.on('error', (error) => events.onError?.(error));
watcher.on('error', (error) => events.onError?.(error as Error));
return () => watcher.close();
}