Skip to content

Commit a579af4

Browse files
committed
fix(visualizer): fix for loop syntax in replay-scripts.ts
- Remove leftover forEach closing bracket - Change return to break in for loop
1 parent 5a5ef02 commit a579af4

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

packages/visualizer/src/utils/replay-scripts.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -512,7 +512,9 @@ export const generateAnimationScripts = async (
512512

513513
if (screenshot) {
514514
const screenshotData =
515-
typeof screenshot === 'string' ? screenshot : await screenshot.getData();
515+
typeof screenshot === 'string'
516+
? screenshot
517+
: await screenshot.getData();
516518
scripts.push({
517519
type: 'img',
518520
img: screenshotData,
@@ -550,9 +552,9 @@ export const generateAnimationScripts = async (
550552
imageWidth: task.uiContext?.size?.width || imageWidth,
551553
imageHeight: task.uiContext?.size?.height || imageHeight,
552554
});
553-
return;
555+
break;
554556
}
555-
});
557+
}
556558

557559
// console.log('scripts', scripts);
558560

0 commit comments

Comments
 (0)