Skip to content

Commit 263e0c5

Browse files
committed
fulfil interface reqs and use const for find result
1 parent 55a1180 commit 263e0c5

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

app/wall/utils.test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ test("updateTargetStationBeamCurrent returns new array with beam current of targ
2929
targetStation: "Target station 123",
3030
beamCurrentPv: beamCurrPv,
3131
beamCurrent: 0.0,
32+
instruments: [],
3233
};
3334
const expectedValue = 3.14159265358979;
3435
expect(

app/wall/utils.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ export function updateTargetStationBeamCurrent(
3939
) {
4040
const newData: Array<targetStation> = [...prev];
4141

42-
let foundTs = newData.find((ts) => ts.beamCurrentPv === updatedPVName);
42+
const foundTs = newData.find((ts) => ts.beamCurrentPv === updatedPVName);
4343
if (foundTs) {
4444
foundTs.beamCurrent = updatedPVvalue;
4545
}

0 commit comments

Comments
 (0)