Completed server status check and separate helper func into different file