Ok, I take back my comment about the API being loose.
The issue I was hitting here when testing was/is due to the mysql ADODB layer allowing values between -65500 and 65500 for BOOLEAN fields – it’s using a TINYINT(4)
Since mysql 5.0.3, the BIT data type exists.
I’m wondering if we should start using BIT on new installs, and give users a step of manual steps to run if they wish to convert.
In any case, I’m updating the phpunit tests I wrote to reflect what’s actually the correct behaviour
Different topic J
I’ve noticed today that the sponsorship API seems very ‘loose’ – is that deliberate?
For example, at an API level, we allow Sponsorship Paid to be set to any value. Logically, I’d expect it to track payment against the initial amount sponsored.
i.e. if someone decides to pay more than their initial sponsorship, I would kind of expect the sponsorship amount to either a) be updated when paying, or b) need to be updated first.
Do we consider this to behaviour a bug, or a deliberate act on our part as it’s there to loosely track and not as an invoicing system ?