Make request over https if loaded that way

I get an error when using an apache ssl proxy:
    The page at 'https://logsearch/_plugin/sense/' was loaded over HTTPS, but displayed insecure content from 'http://logsearch/_search': this content should also be loaded over HTTPS.

This is resolved by adding https:// to the front of the server and saves users having to manually modify the provided default value