mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-20 11:48:30 -06:00
Little refactor of account.c
This commit is contained in:
parent
444eb1c28e
commit
7b1d298bc6
@ -4444,17 +4444,17 @@ xaccAccountGetReconcilePostponeBalance (const Account *acc,
|
||||
g_return_val_if_fail(GNC_IS_ACCOUNT(acc), FALSE);
|
||||
qof_instance_get_kvp (QOF_INSTANCE(acc),
|
||||
"reconcile-info/postpone/balance", &v);
|
||||
if (G_VALUE_HOLDS_INT64 (&v)) {
|
||||
bal = *(gnc_numeric*)g_value_get_boxed (&v);
|
||||
if (!G_VALUE_HOLDS_INT64 (&v))
|
||||
return FALSE;
|
||||
|
||||
if (bal.denom)
|
||||
{
|
||||
if (balance)
|
||||
*balance = bal;
|
||||
return TRUE;
|
||||
}
|
||||
}
|
||||
return FALSE;
|
||||
bal = *(gnc_numeric*)g_value_get_boxed (&v);
|
||||
if (!bal.denom)
|
||||
return FALSE;
|
||||
|
||||
if (balance)
|
||||
*balance = bal;
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
/********************************************************************\
|
||||
|
Loading…
Reference in New Issue
Block a user