Make sure there is at least one results.

If MariaDB cannot connect to Sphinx, it can return an empty array.
Keep typcasting since otherwise it returns buffers.
Set the database's port number.
Changed the config file to send an array of databases.

A single object works too, but an array is preferred.
Handle a down connection (mariasql).
Handle a down connection (node-mysql).
Removed some debugging code.