= FALSE) { $roles = []; if ($this->request->headers->has('X-Consumer-Groups')) { $roles += preg_split("/,\s?/", $this->request->headers ->get('X-Consumer-Groups')); } if (!$exclude_locked_roles) { $roles[] = RoleInterface::AUTHENTICATED_ID; } return $roles; }