Cleaned up some syntax, Changed logging to print port number to both console and log file