From 6df4a971c38596c6068e0f818ab60ac938395174 Mon Sep 17 00:00:00 2001 From: redshiftzero Date: Mon, 27 Jan 2025 15:26:52 -0500 Subject: [PATCH] fix: make `writeJSONArray` generic --- src/account_x/x_account_controller.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/account_x/x_account_controller.ts b/src/account_x/x_account_controller.ts index 23b82161..420ab736 100644 --- a/src/account_x/x_account_controller.ts +++ b/src/account_x/x_account_controller.ts @@ -1272,7 +1272,7 @@ export class XAccountController { await archiveZip.extract({ path: getAccountDataPath("X", this.account.username) }); } - async writeJSONArray(streamWriter: fs.WriteStream, items: any[], propertyName: string) { + async writeJSONArray(streamWriter: fs.WriteStream, items: T[], propertyName: string) { streamWriter.write(` "${propertyName}": [\n`); for (let i = 0; i < items.length; i++) { const suffix = i < items.length - 1 ? ',\n' : '\n';