Added more types.

This commit is contained in:
SamTV12345 2024-01-30 22:26:05 +01:00
parent 03e73053cb
commit 6fdf9ed812
4 changed files with 7 additions and 6 deletions

View file

@ -17,7 +17,7 @@ const stats = require('../stats');
const util = require('util');
const webaccess = require('./express/webaccess');
const SecretRotator = require('../security/SecretRotator')
import SecretRotator from '../security/SecretRotator';
// TODO once we have ESM we can use the type of the class
let secretRotator: any|null = null;

View file

@ -1,4 +1,4 @@
'use strict';
import {DeriveModel} from "../types/DeriveModel";
import {LegacyParams} from "../types/LegacyParams";
@ -261,4 +261,4 @@ export class SecretRotator {
}
}
module.exports = SecretRotator;
export default SecretRotator

View file

@ -28,7 +28,7 @@ import {PluginType} from "./types/Plugin";
import {ErrorCaused} from "./types/ErrorCaused";
import {PromiseHooks} from "node:v8";
const log4js = require('log4js');
import log4js from 'log4js';
const settings = require('./utils/Settings');
@ -55,7 +55,7 @@ const pluginDefs = require('../static/js/pluginfw/plugin_defs');
const plugins = require('../static/js/pluginfw/plugins');
const installer = require('../static/js/pluginfw/installer');
const {Gate} = require('./utils/promises');
const stats = require('./stats');
import * as stats from './stats';
const logger = log4js.getLogger('server');

View file

@ -1,6 +1,7 @@
'use strict';
const measured = require('measured-core');
// @ts-ignore
import measured from 'measured-core';
module.exports = measured.createCollection();