Skip to content

Commit bd820f0

Browse files
committed
err handle for action.jsx
1 parent b9889e4 commit bd820f0

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/app/components/Action.jsx

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,9 @@ const Action = props => {
1111

1212
// display render time for state change in seconds and miliseconds
1313
const cleanTime = () => {
14+
if (!componentData.actualDuration) {
15+
return 'NO TIME';
16+
}
1417
let seconds;
1518
let miliseconds = componentData.actualDuration;
1619
if (Math.floor(componentData.actualDuration) > 60) {
@@ -23,7 +26,7 @@ const Action = props => {
2326
} else {
2427
seconds = '00';
2528
}
26-
miliseconds = Number.parseFloat(miliseconds).toFixed(2)
29+
miliseconds = Number.parseFloat(miliseconds).toFixed(2);
2730
const arrayMiliseconds = miliseconds.split('.');
2831
if (arrayMiliseconds[0].length < 2) {
2932
arrayMiliseconds[0] = '0'.concat(arrayMiliseconds[0]);

0 commit comments

Comments
 (0)