import { EmptyObject } from '../types/EmptyObject';
import { FileType } from '../types/FileType';
import { HandleErrorParams } from '../types/Error';
import { EmptyObject } from '../types/EmptyObject';
import { FileType } from '../types/FileType';
import { HandleErrorParams } from '../types/Error';
import Utils from './Utils';
import chalk from 'chalk';
import fs from 'fs';
import logger from './Logger';
export default class FileUtils {
import Utils from './Utils';
import chalk from 'chalk';
import fs from 'fs';
import logger from './Logger';
export default class FileUtils {
if (filename && event === 'change') {
try {
logger.debug(logPrefix + ' ' + fileType + ' file ' + file + ' have changed, reload');
if (filename && event === 'change') {
try {
logger.debug(logPrefix + ' ' + fileType + ' file ' + file + ' have changed, reload');
} catch (error) {
FileUtils.handleFileException(logPrefix, fileType, file, error as NodeJS.ErrnoException, {
throwError: false,
} catch (error) {
FileUtils.handleFileException(logPrefix, fileType, file, error as NodeJS.ErrnoException, {
throwError: false,