Fix bad typings left over from the migration

This commit is contained in:
Hornwitser committed 2023-11-19 04:50:07 +01:00
1 parent 7314dc99c8
commit 80e1904175
22 files changed
+93 -117

No files matched your search

+2 -2
View File
@@ -688,7 +688,7 @@ export default class Host extends lib.Link {
url.pathname += `api/stream/${streamId}`;
let response = await phin({
url, method: "GET",
core: { ca: this.tlsCa } as {},
core: { ca: this.tlsCa } as object,
stream: true,
});
@@ -743,7 +743,7 @@ export default class Host extends lib.Link {
url.pathname += `api/stream/${streamId}`;
phin({
url, method: "PUT",
core: { ca: this.tlsCa } as {},
core: { ca: this.tlsCa } as object,
data: content,
}).catch(err => {
logger.error(`Error pushing save to controller:\n${err.stack}`, this.instanceLogMeta(instanceId));
+1 -1
View File
@@ -1067,7 +1067,7 @@ rcon.print(game.table_to_json(players))`.replace(/\r?\n/g, " ");
let response = await phin({
url, method: "PUT",
data: content,
core: { ca: this._host.tlsCa } as {},
core: { ca: this._host.tlsCa } as object,
headers: {
"Content-Type": "application/zip",
"x-access-token": this._host.config.get("host.controller_token"),
+2 -2
View File
@@ -692,9 +692,9 @@ export class FactorioServer extends events.EventEmitter {
this._maxConcurrentCommands = value;
this.setMaxListeners(value + 5);
if (this._rconClient) {
// @ts-ignore
// @ts-expect-error sendQueue is private
if (this._rconClient.sendQueue) {
// @ts-ignore
// @ts-expect-error sendQueue is private
this._rconClient.sendQueue.maxConcurrent = value;
}
// XXX: Workaround to suppress bogus event listener warning