Move client listen statement to bottom