mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Bug 722123 - Zero price entry added to price database on stock purchase
Ensure that a 0 price isn't written from the stock register.
This commit is contained in:
parent
d0766a6bb4
commit
e421123ef7
@ -2247,6 +2247,7 @@ gnc_split_register_auto_calc (SplitRegister *reg, Split *split)
|
|||||||
cell = (PriceCell *) gnc_table_layout_get_cell (reg->table->layout,
|
cell = (PriceCell *) gnc_table_layout_get_cell (reg->table->layout,
|
||||||
PRIC_CELL);
|
PRIC_CELL);
|
||||||
price = gnc_price_cell_get_value (cell);
|
price = gnc_price_cell_get_value (cell);
|
||||||
|
if (price > 0)
|
||||||
record_price (reg, account, price);
|
record_price (reg, account, price);
|
||||||
}
|
}
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
Loading…
Reference in New Issue
Block a user