-
-
Notifications
You must be signed in to change notification settings - Fork 4.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(setupcheck): Check several config values to be valid URLs (and more) #45382
base: master
Are you sure you want to change the base?
Conversation
…ore) Signed-off-by: Joas Schilling <coding@schilljs.com>
} | ||
|
||
if (filter_var($parts[0], FILTER_VALIDATE_IP, FILTER_FLAG_IPV4)) { | ||
if (!is_numeric($parts[1]) || $parts[1] > 32 || $parts[1] < 1) { |
Check notice
Code scanning / Psalm
PossiblyUndefinedArrayOffset Note
return SetupResult::error($this->l10n->t('Config value %s is not an valid IP address or IP range.', [$configKey])); | ||
} | ||
} elseif (filter_var($parts[0], FILTER_VALIDATE_IP, FILTER_FLAG_IPV6)) { | ||
if (!is_numeric($parts[1]) || $parts[1] > 128 || $parts[1] < 1) { |
Check notice
Code scanning / Psalm
PossiblyUndefinedArrayOffset Note
Good idea 👍 Some people were confused with the well-known setup check because it stops on the first failure. I fear this could be confusing here as well if you encounter many issues in the configuration file. |
trusted_domains
andoverwrite.cli.url
sensitive config values #45085TODO
Checklist