Fix to get device for ws from url

* change getDevFromURL to get from actual URL
* Formatting
* Reclassified some logging messages