I will submit a new PR request using opts.getHost.

But I must admit that I'm confused about why you say the current code wouldn't work. Since the constructor on any adapter instance is called exactly once does that guarantee that we will never visit this spot again for this particular instance of the adapter? In other words, for any instance of the adapter shouldn't line 139 run exactly 1 time and never again?