fixing console log in getConnection