use location for default ws and fix disconnect crash