fixes on connection variable, more work on login