Update redraw_connection function