Skip to content

Commit

Permalink
update server packages
Browse files Browse the repository at this point in the history
  • Loading branch information
l3tnun committed Oct 30, 2021
1 parent 3ee0706 commit 6c9a9a8
Show file tree
Hide file tree
Showing 118 changed files with 1,357 additions and 1,604 deletions.
2 changes: 1 addition & 1 deletion config/enc-enhance.js.template
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ const getDuration = filePath => {
try {
const result = JSON.parse(stdout);
resolve(parseFloat(result.format.duration));
} catch (err) {
} catch (err: any) {
reject(err);
}
});
Expand Down
2,419 changes: 1,088 additions & 1,331 deletions package-lock.json

Large diffs are not rendered by default.

39 changes: 19 additions & 20 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,61 +32,60 @@
"dependencies": {
"arib-subtitle-timedmetadater": "4.0.9",
"aribts": "2.1.12",
"axios": "0.21.1",
"axios": "0.24.0",
"body-parser": "1.19.0",
"cors": "2.8.5",
"diskusage-ng": "1.0.2",
"express": "4.17.1",
"express-openapi": "9.1.0",
"express-openapi": "9.3.0",
"file-type": "16.5.3",
"inversify": "5.1.1",
"js-yaml": "4.1.0",
"lodash": "4.17.21",
"log4js": "6.3.0",
"minimist": "1.2.5",
"mirakurun": "3.9.0-beta.1",
"mirakurun": "3.9.0-beta.17",
"mkdirp": "1.0.4",
"multer": "1.4.2",
"multer": "1.4.3",
"mysql": "2.18.1",
"openapi-types": "9.1.0",
"openapi-types": "9.3.0",
"reflect-metadata": "0.1.13",
"socket.io": "4.1.3",
"source-map-support": "0.5.19",
"socket.io": "4.3.1",
"source-map-support": "0.5.20",
"sqlite3": "5.0.2",
"swagger-ui-dist": "3.51.2",
"typeorm": "0.2.36",
"swagger-ui-dist": "3.52.5",
"typeorm": "0.2.38",
"url-join": "4.0.1"
},
"devDependencies": {
"@types/body-parser": "1.19.1",
"@types/express": "4.17.13",
"@types/file-type": "10.9.1",
"@types/js-yaml": "4.0.2",
"@types/lodash": "4.14.172",
"@types/js-yaml": "4.0.4",
"@types/lodash": "4.14.176",
"@types/minimist": "1.2.2",
"@types/mkdirp": "1.0.2",
"@types/mongodb": "4.0.6",
"@types/multer": "1.4.7",
"@types/node": "16.4.13",
"@types/node": "16.11.6",
"@types/socket.io": "3.0.1",
"@types/source-map-support": "0.5.4",
"@types/sqlite3": "3.1.7",
"@types/url-join": "4.0.1",
"@typescript-eslint/eslint-plugin": "4.29.0",
"@typescript-eslint/parser": "4.29.0",
"@typescript-eslint/eslint-plugin": "4.33.0",
"@typescript-eslint/parser": "4.33.0",
"del": "6.0.0",
"eslint": "7.32.0",
"eslint-config-prettier": "8.3.0",
"eslint-plugin-prettier": "3.4.0",
"eslint-plugin-prettier": "3.4.1",
"gulp": "4.0.2",
"gulp-eslint": "6.0.0",
"gulp-plumber": "1.2.1",
"gulp-sourcemaps": "3.0.0",
"gulp-typescript": "5.0.1",
"i": "0.3.6",
"prettier": "2.3.2",
"ts-loader": "9.2.5",
"ts-node": "10.2.0",
"typescript": "4.3.5"
"prettier": "2.4.1",
"ts-loader": "9.2.6",
"ts-node": "10.4.0",
"typescript": "4.4.4"
}
}
2 changes: 1 addition & 1 deletion src/DBTools.ts
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ class DBTools {
throw new Error('file is null');
}
backup = JSON.parse(file);
} catch (err) {
} catch (err: any) {
if (err.code === 'ENOENT') {
console.error(`${this.filePath} is not found`);
process.exit(1);
Expand Down
2 changes: 1 addition & 1 deletion src/V1MigrationTool.ts
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ class V1MigrationTool {
}

return JSON.parse(file);
} catch (err) {
} catch (err: any) {
if (err.code === 'ENOENT') {
this.log.system.error(`${this.v1BackupFilePath} is not found`);
process.exit(1);
Expand Down
2 changes: 1 addition & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ const runEPGUpdater = async () => {
(async () => {
try {
await init();
} catch (err) {
} catch (err: any) {
console.error('initialize error');
console.error(err);
process.exit(1);
Expand Down
6 changes: 3 additions & 3 deletions src/model/Configuration.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ class Configuration implements IConfiguration {

try {
this.templateConfig = this.readConfig(Configuration.CONFIG_TEMPLATE_FILE_PATH, true);
} catch (err) {
} catch (err: any) {
this.templateConfig = null;
}

Expand All @@ -35,7 +35,7 @@ class Configuration implements IConfiguration {
try {
const newConfig = <any>yaml.load(await fs.promises.readFile(Configuration.CONFIG_FILE_PATH, 'utf-8'));
this.config = this.formatConfig(newConfig);
} catch (err) {
} catch (err: any) {
this.log.system.error('read config error');
this.log.system.error(err);
}
Expand All @@ -52,7 +52,7 @@ class Configuration implements IConfiguration {
let str: string = '';
try {
str = fs.readFileSync(configPath, 'utf-8');
} catch (e) {
} catch (e: any) {
if (e.code === 'ENOENT') {
const errMsg = `${configPath} is not found`;
if (isWarning === true) {
Expand Down
4 changes: 2 additions & 2 deletions src/model/ConnectionCheckModel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ export default class ConnectionCheckModel implements IConnectionCheckModel {
this.log.system.info('check mirakurun');
await this.mirakurunClient.getStatus();
break;
} catch (err) {
} catch (err: any) {
await Util.sleep(1000);
}
}
Expand All @@ -48,7 +48,7 @@ export default class ConnectionCheckModel implements IConnectionCheckModel {
this.log.system.info('check db');
await this.dbOperator.checkConnection();
break;
} catch (err) {
} catch (err: any) {
await Util.sleep(1000);
}
}
Expand Down
4 changes: 2 additions & 2 deletions src/model/LoggerModel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ export default class LoggerModel implements ILoggerModel {
const str = this.readLogFile(filePath);
const config: log4js.Configuration = yaml.load(str) as any;
log4js.configure(config);
} catch (err) {
} catch (err: any) {
console.error('log file parse error');
process.exit(1);
}
Expand Down Expand Up @@ -78,7 +78,7 @@ export default class LoggerModel implements ILoggerModel {
let str: string = '';
try {
str = fs.readFileSync(filePath, 'utf-8');
} catch (err) {
} catch (err: any) {
if (err.code === 'ENOENT') {
console.error('log file is not found');
} else {
Expand Down
12 changes: 6 additions & 6 deletions src/model/ModelContainerSetter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,7 @@ export const set = (container: Container): void => {
try {
const recorderModel = context.container.get<IRecorderModel>('IRecorderModel');
resolve(recorderModel);
} catch (err) {
} catch (err: any) {
reject(err);
}
},
Expand Down Expand Up @@ -328,7 +328,7 @@ export const set = (container: Container): void => {
try {
const encoderModel = context.container.get<IEncoderModel>('IEncoderModel');
resolve(encoderModel);
} catch (err) {
} catch (err: any) {
reject(err);
}
},
Expand All @@ -348,7 +348,7 @@ export const set = (container: Container): void => {
try {
const streamModel = context.container.get<ILiveStreamBaseModel>('LiveStreamModel');
resolve(streamModel);
} catch (err) {
} catch (err: any) {
reject(err);
}
});
Expand All @@ -365,7 +365,7 @@ export const set = (container: Container): void => {
try {
const streamModel = context.container.get<ILiveStreamBaseModel>('LiveHLSStreamModel');
resolve(streamModel);
} catch (err) {
} catch (err: any) {
reject(err);
}
});
Expand All @@ -380,7 +380,7 @@ export const set = (container: Container): void => {
try {
const streamModel = context.container.get<IRecordedStreamBaseModel>('RecordedStreamModel');
resolve(streamModel);
} catch (err) {
} catch (err: any) {
reject(err);
}
});
Expand All @@ -394,7 +394,7 @@ export const set = (container: Container): void => {
try {
const streamModel = context.container.get<IRecordedStreamBaseModel>('RecordedHLSStreamModel');
resolve(streamModel);
} catch (err) {
} catch (err: any) {
reject(err);
}
});
Expand Down
2 changes: 1 addition & 1 deletion src/model/PromiseRetry.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export default class PromiseRetry implements IPromiseRetry {
const result: T = await job();

return result;
} catch (err) {
} catch (err: any) {
error = err;

await Util.sleep(
Expand Down
2 changes: 1 addition & 1 deletion src/model/api/video/VideoUtil.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ export default class VideoUtil implements IVideoUtil {
size: parseInt(result.format.size, 10),
bitRate: parseFloat(result.format.bit_rate),
});
} catch (err) {
} catch (err: any) {
reject(err);
}
});
Expand Down
2 changes: 1 addition & 1 deletion src/model/db/ChannelDB.ts
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ export default class ChannelDB implements IChannelDB {
}

await queryRunner.commitTransaction();
} catch (err) {
} catch (err: any) {
console.error(err);
hasError = true;
await queryRunner.rollbackTransaction();
Expand Down
2 changes: 1 addition & 1 deletion src/model/db/DropLogFileDB.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ export default class DropLogFileDB implements IDropLogFileDB {
await queryRunner.manager.insert(DropLogFile, item);
}
await queryRunner.commitTransaction();
} catch (err) {
} catch (err: any) {
console.error(err);
hasError = err;
await queryRunner.rollbackTransaction();
Expand Down
4 changes: 2 additions & 2 deletions src/model/db/ProgramDB.ts
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ export default class ProgramDB implements IProgramDB {
}

await queryRunner.commitTransaction();
} catch (err) {
} catch (err: any) {
console.error(err);
hasError = true;
await queryRunner.rollbackTransaction();
Expand Down Expand Up @@ -318,7 +318,7 @@ export default class ProgramDB implements IProgramDB {
}

await queryRunner.commitTransaction();
} catch (err) {
} catch (err: any) {
console.error(err);
hasError = true;
await queryRunner.rollbackTransaction();
Expand Down
2 changes: 1 addition & 1 deletion src/model/db/RecordedDB.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ export default class RecordedDB implements IRecordedDB {
await queryRunner.manager.insert(Recorded, item);
}
await queryRunner.commitTransaction();
} catch (err) {
} catch (err: any) {
console.error(err);
hasError = err;
await queryRunner.rollbackTransaction();
Expand Down
2 changes: 1 addition & 1 deletion src/model/db/RecordedHistoryDB.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ export default class RecordedHistoryDB implements IRecordedHistoryDB {
await queryRunner.manager.insert(RecordedHistory, item);
}
await queryRunner.commitTransaction();
} catch (err) {
} catch (err: any) {
console.error(err);
hasError = err;
await queryRunner.rollbackTransaction();
Expand Down
2 changes: 1 addition & 1 deletion src/model/db/RecordedTagDB.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ export default class RecordedTagDB implements IRecordedTagDB {
await queryRunner.manager.insert(RecordedTag, item);
}
await queryRunner.commitTransaction();
} catch (err) {
} catch (err: any) {
console.error(err);
hasError = err;
await queryRunner.rollbackTransaction();
Expand Down
4 changes: 2 additions & 2 deletions src/model/db/ReserveDB.ts
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ export default class ReserveDB implements IReserveDB {
await queryRunner.manager.insert(Reserve, item);
}
await queryRunner.commitTransaction();
} catch (err) {
} catch (err: any) {
console.error(err);
hasError = err;
await queryRunner.rollbackTransaction();
Expand Down Expand Up @@ -130,7 +130,7 @@ export default class ReserveDB implements IReserveDB {
}

await queryRunner.commitTransaction();
} catch (err) {
} catch (err: any) {
console.error(err);
hasError = true;
await queryRunner.rollbackTransaction();
Expand Down
2 changes: 1 addition & 1 deletion src/model/db/RuleDB.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ export default class RuleDB implements IRuleDB {
await queryRunner.manager.insert(Rule, this.convertRuleToDBRule(item));
}
await queryRunner.commitTransaction();
} catch (err) {
} catch (err: any) {
console.error(err);
hasError = err;
await queryRunner.rollbackTransaction();
Expand Down
2 changes: 1 addition & 1 deletion src/model/db/ThumbnailDB.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ export default class ThumbnailDB implements IThumbnailDB {
await queryRunner.manager.insert(Thumbnail, item);
}
await queryRunner.commitTransaction();
} catch (err) {
} catch (err: any) {
console.error(err);
hasError = err;
await queryRunner.rollbackTransaction();
Expand Down
2 changes: 1 addition & 1 deletion src/model/db/VideoFileDB.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ export default class VideoFileDB implements IVideoFileDB {
await queryRunner.manager.insert(VideoFile, item);
}
await queryRunner.commitTransaction();
} catch (err) {
} catch (err: any) {
console.error(err);
hasError = err;
await queryRunner.rollbackTransaction();
Expand Down
Loading

0 comments on commit 6c9a9a8

Please sign in to comment.