cms
cms copied to clipboard
Site base URL prefixed with "http://" if set to an environment variable not currently in .env
Description
If a site's "Base URL" setting is set to an environment variable (i.e. any value starting with a $) that doesn't actually have a corresponding key in .env, upon saving the site Craft prefixes the value with "http://", which feels like a bug.

Steps to reproduce
- Set the "Base URL" setting to a non-existent environment variable (e.g.
$FOOBAR) - Save the site
- Confirm that Craft has prefixed the environment variable with "http://"
Additional info
- Craft version: 3.5.0-RC6
- PHP version:
- Database driver & version:
- Plugins & versions:
We’ll have to think about the best way to address this. Part of me is thinking we should just stop validating any values that are set to an environment variable altogether.