Worker origin needs to take into account server port number
Dealt with empty location.port
Merge pull request #817 from plehegar/plh/worker-origin-fix

Worker origin needs to take into account server port number