Refactor connected to allow operation separation