Recover getPort() function to provide previous functionality for "grunt serve"