Commit 645d13b1 authored by Ben Hayward's avatar Ben Hayward

Allow specific flags, and false values

1 merge request!337[Sprint/NuancedNumbat](feat): Enable feature flags when staging cookie set. #857
Pipeline #83886395 failed with stages
in 4 minutes and 11 seconds
......@@ -49,8 +49,9 @@ class Manager
{
$features = $this->config->get('features') ?: [];
if (isset($_COOKIE['staging'])) {
return true;
$featureOverrides ?? json_decode(base64_decode($_COOKIE['staging-features']), true);
if ($featureOverrides[$feature]) {
return $featureOverrides[$feature];
}
if (!isset($features[$feature])) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment