Skip to content

Commit 247f978

Browse files
Ensure to use const where possible
1 parent b350853 commit 247f978

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/matrix.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,8 @@ export class SparseMatrix {
4444
this.nRows = dims[0];
4545
this.nCols = dims[1];
4646
for (let i = 0; i < values.length; i++) {
47-
var row = rows[i];
48-
var col = cols[i];
47+
const row = rows[i];
48+
const col = cols[i];
4949
this.checkDims(row, col);
5050
const key = this.makeKey(row, col);
5151
this.entries.set(key, { value: values[i], row, col });

src/umap.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -809,7 +809,7 @@ export class UMAP {
809809
const weights: number[] = [];
810810
const head: number[] = [];
811811
const tail: number[] = [];
812-
var rowColValues = graph.getAll();
812+
const rowColValues = graph.getAll();
813813
for (let i = 0; i < rowColValues.length; i++) {
814814
const entry = rowColValues[i];
815815
if (entry.value) {

0 commit comments

Comments
 (0)