Authenticate on init, rather than before

We can't authenticate before the query is set up, so we need to only do so on init or afterwards.

Fixes #15.