Skip to content

Commit

Permalink
Merge pull request #51 from evo-company/fix-loading-text-stuck
Browse files Browse the repository at this point in the history
fix stuck loading text on ui
  • Loading branch information
kindermax authored Dec 17, 2024
2 parents 031f14d + 7865f48 commit f18ecff
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions ui/src/Dashboard/Flag.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -148,9 +148,9 @@ const HistoryModal = ({ flagId, open, onClose, createdTimestamp, reportedTimesta
}
}, [open]);

if (loading || !data) {
return <p>Loading...</p>;
};
if (!open || loading || !data) {
return null;
}

const { flag: { changes } } = data;

Expand Down
6 changes: 3 additions & 3 deletions ui/src/Dashboard/Value.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -163,9 +163,9 @@ const HistoryModal = ({ valueId, open, onClose, createdTimestamp, reportedTimest
}
}, [open]);

if (loading || !data) {
return <p>Loading...</p>;
};
if (!open || loading || !data) {
return null;
}

const { value: { changes } } = data;

Expand Down

0 comments on commit f18ecff

Please sign in to comment.