Skip to content

Commit e83bb82

Browse files
committed
Fix more lint errors
1 parent c2e8db7 commit e83bb82

File tree

5 files changed

+14
-3
lines changed

5 files changed

+14
-3
lines changed

src/debugger/godot3/variables/variant_encoder.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -125,6 +125,7 @@ export class VariantEncoder {
125125
private encode_Array(arr: any[], model: BufferModel) {
126126
const size = arr.length;
127127
this.encode_UInt32(size, model);
128+
// biome-ignore lint/complexity/noForEach: <explanation>
128129
arr.forEach((e) => {
129130
this.encode_variant(e, model);
130131
});
@@ -151,6 +152,7 @@ export class VariantEncoder {
151152
const size = dict.size;
152153
this.encode_UInt32(size, model);
153154
const keys = Array.from(dict.keys());
155+
// biome-ignore lint/complexity/noForEach: <explanation>
154156
keys.forEach((key) => {
155157
const value = dict.get(key);
156158
this.encode_variant(key, model);
@@ -239,6 +241,7 @@ export class VariantEncoder {
239241
private size_Dictionary(dict: Map<any, any>): number {
240242
let size = this.size_UInt32();
241243
const keys = Array.from(dict.keys());
244+
// biome-ignore lint/complexity/noForEach: <explanation>
242245
keys.forEach((key) => {
243246
const value = dict.get(key);
244247
size += this.size_variant(key);
@@ -266,6 +269,7 @@ export class VariantEncoder {
266269

267270
private size_array(arr: any[]): number {
268271
let size = this.size_UInt32();
272+
// biome-ignore lint/complexity/noForEach: <explanation>
269273
arr.forEach((e) => {
270274
size += this.size_variant(e);
271275
});
@@ -316,6 +320,7 @@ export class VariantEncoder {
316320
size += this.size_Dictionary(value);
317321
break;
318322
} else {
323+
// biome-ignore lint/complexity/useLiteralKeys: <explanation>
319324
switch (value["__type__"]) {
320325
case "Vector2":
321326
size += this.size_UInt32() * 2;

src/debugger/godot4/variables/variables_manager.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -235,6 +235,7 @@ export class VariablesManager {
235235
new GodotIdWithPath(parent_godot_id, [...relative_path, va.name]),
236236
);
237237
} else if (value instanceof Map) {
238+
// biome-ignore lint/complexity/useLiteralKeys: <explanation>
238239
rendered_value = value["class_name"] ?? `Dictionary(${value.size})`;
239240
reference = mapper.get_or_create_vscode_id(
240241
new GodotIdWithPath(parent_godot_id, [...relative_path, va.name]),

src/debugger/godot4/variables/variant_encoder.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,6 +154,7 @@ export class VariantEncoder {
154154
private encode_Array(arr: any[], model: BufferModel) {
155155
const size = arr.length;
156156
this.encode_UInt32(size, model);
157+
// biome-ignore lint/complexity/noForEach: <explanation>
157158
arr.forEach((e) => {
158159
this.encode_variant(e, model);
159160
});
@@ -180,6 +181,7 @@ export class VariantEncoder {
180181
const size = dict.size;
181182
this.encode_UInt32(size, model);
182183
const keys = Array.from(dict.keys());
184+
// biome-ignore lint/complexity/noForEach: <explanation>
183185
keys.forEach((key) => {
184186
const value = dict.get(key);
185187
this.encode_variant(key, model);
@@ -314,6 +316,7 @@ export class VariantEncoder {
314316
private size_Dictionary(dict: Map<any, any>): number {
315317
let size = this.size_UInt32();
316318
const keys = Array.from(dict.keys());
319+
// biome-ignore lint/complexity/noForEach: <explanation>
317320
keys.forEach((key) => {
318321
const value = dict.get(key);
319322
size += this.size_variant(key);
@@ -341,6 +344,7 @@ export class VariantEncoder {
341344

342345
private size_array(arr: any[]): number {
343346
let size = this.size_UInt32();
347+
// biome-ignore lint/complexity/noForEach: <explanation>
344348
arr.forEach((e) => {
345349
size += this.size_variant(e);
346350
});
@@ -395,6 +399,7 @@ export class VariantEncoder {
395399
size += this.size_String(value.value);
396400
break;
397401
} else {
402+
// biome-ignore lint/complexity/useLiteralKeys: <explanation>
398403
switch (value["__type__"]) {
399404
case "Vector2":
400405
case "Vector2i":

src/extension.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -259,14 +259,14 @@ class GodotEditorTerminal implements vscode.Pseudoterminal {
259259
proc.stdout.on("data", (data) => {
260260
const out = data.toString().trim();
261261
if (out) {
262-
this.writeEmitter.fire(data + "\r\n");
262+
this.writeEmitter.fire(`${data}\r\n`);
263263
}
264264
});
265265

266266
proc.stderr.on("data", (data) => {
267267
const out = data.toString().trim();
268268
if (out) {
269-
this.writeEmitter.fire(data + "\r\n");
269+
this.writeEmitter.fire(`${data}\r\n`);
270270
}
271271
});
272272

src/utils/godot_utils.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ export async function convert_uids_to_uris(uids: string[]): Promise<Map<string,
133133
const not_found_uids: string[] = [];
134134
const uris: Map<string, vscode.Uri> = new Map();
135135

136-
let found_all: boolean = true;
136+
let found_all = true;
137137
for (const uid of uids) {
138138
if (!uid.startsWith("uid://")) {
139139
continue;

0 commit comments

Comments
 (0)