Skip to content

Commit

Permalink
fix: incorrect remaining grams
Browse files Browse the repository at this point in the history
  • Loading branch information
marcelblijleven committed Oct 17, 2023
1 parent 5a39b50 commit 27d0f62
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/app/beanconqueror/stats/components/backlog-table.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@ const BacklogTable = (props: BacklogTableProps) => (
<TableBody>
{props.beans.map(bean => {
const usage = props.usage[bean.config.uuid] || 0;
const remaining = (bean.weight || 0 - usage).toFixed(2);
const remaining = !!bean.weight ? (bean.weight - usage).toFixed(2) : "-"

return (
<TableRow key={bean.config.uuid}>
<TableCell >{getTextWithFlagSupport(bean.name)}</TableCell>
Expand Down

0 comments on commit 27d0f62

Please sign in to comment.