fix for using livereload.js over https

we detect protocol through global location variable and then set our websocket protocol to either 'wss' or 'ws'.