Fixed returning null on dbQuery::first() instead of empty array
PHP 5.2 compatibility fixes