Merge pull request #1802 from benphelps/fix/issue-1747

Fix jobStats potentially accessed before instantiated
pull/1820/head
shamoon 1 year ago committed by GitHub
commit 3b1c9a69a4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -31,7 +31,7 @@ export default function Component({ service }) {
const printingStateFalgs = ["Printing", "Paused", "Pausing", "Resuming"];
if (printingStateFalgs.includes(state)) {
const { completion } = jobStats.progress;
const { completion } = jobStats?.progress ?? undefined;
if (!jobStats || !completion) {
return (

Loading…
Cancel
Save