Fix sqlite3.Cursor.fetchone() misuse (#4464).

Note that there's another use of `fetchone()[0]` (http://bazaar.launchpad.net/~ubuntuone-control-tower/u1db/trunk/view/head:/u1db/backends/sqlite_backend.py#L68), but if that one assumes that the db has been initialized correctly, and if it was not, the whole initialization routine would break. So I'm fixing just the one you pointed, which is related to retrieving the generation of a database.