mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Delete Account: Short circuit checks if no transactions or subaccounts
Count of splits and number of children need to be or'd
This commit is contained in:
@@ -1605,7 +1605,7 @@ gnc_plugin_page_account_tree_cmd_delete_account (GtkAction *action, GncPluginPag
|
||||
}
|
||||
|
||||
// If no transaction or children just delete it.
|
||||
if (!(xaccAccountCountSplits (account, FALSE) &&
|
||||
if (!(xaccAccountCountSplits (account, FALSE) ||
|
||||
gnc_account_n_children (account)))
|
||||
{
|
||||
do_delete_account (account, NULL, NULL, NULL);
|
||||
|
||||
Reference in New Issue
Block a user