Fixes connection issues