Stored Calculations not being saved

I have a table “facturas” with three stored calculations:

total with this code:

if(utils.hasRecords(facturas_to_albaranes)){
	return facturas_to_albaranes.sum_total_pd;     // Which is an aggregation in the table albaranes
}
return 0;

pagado with this code:

if(utils.hasRecords(facturas_to_lineas_pagos_clientes)){
	return facturas_to_lineas_pagos_clientes.sumImporte;     // Which is an aggregation in the table lineas_pagos_clientes
}
return 0;

pendiente with this code:

return total-pagado;    // This is just the last two fields

The facturas table is invoices and it is filled when the user wants to with data from other tables, likes services, etc. The first two calculations are being stored only if I do a ```
databaseManager.recalculate(_record)


Am I missing anything?

Thanks.

Forget about this post!! forget about me!! :oops: :oops:

I´m sorry, but I made a typo. The big problem was that the calculation name was pendiene and the field name pendiente.

I do not know what to do: sleep more hours or change my keyboard, but I have to do something.

Sorry again.