if (filename && event === 'change') {
try {
logger.debug(logPrefix + ' ' + fileType + ' file ' + file + ' have changed, reload');
- attribute = JSON.parse(fs.readFileSync(file, 'utf8')) as T;
+ attribute && (attribute = JSON.parse(fs.readFileSync(file, 'utf8')) as T);
} catch (error) {
FileUtils.handleFileException(logPrefix, fileType, file, error as NodeJS.ErrnoException, {
throwError: false,