clear out api object after logging in

@brandur I don't really want to add this, but it might solve that problem