Return empty array instead of false in Db::q
What does this MR do?
Our database query methods, especially
qCol, have been returning
false instead of
, when there was no result.
In result, all usages of the results, where a
foreach is typical, would need to check the result before using.
This does not happen in quite some places, leading to warnings.
This MR returns an empty array instead of replacing it by false.
It does not touch a single other line, because
 == falseevaluates to true
- our codebase does only have a handful of
===which are not connected to database queries
How confident are you it won't break things if deployed?
I trust in my above reasoning but would not really be surprised if I missed something...
Links to related issues
- added a test, or explain why one is not needed/possible...
- no unrelated changes
- asked someone for a code review
- joined #foodsharing-beta channel at https://slackin.yunity.org
- added an entry to CHANGELOG.md (description, merge request link, username(s))