Changed connect() to use hash params