Index: components/policy/core/common/schema_map.cc |
diff --git a/components/policy/core/common/schema_map.cc b/components/policy/core/common/schema_map.cc |
index 90d62c56e4f4d4fde43f013c6c48359e1568675a..dd2a3294e4bc645d7133725c2fbc641651b0e897 100644 |
--- a/components/policy/core/common/schema_map.cc |
+++ b/components/policy/core/common/schema_map.cc |
@@ -70,10 +70,10 @@ void SchemaMap::FilterBundle(PolicyBundle* bundle) const { |
SCHEMA_STRICT, |
&error_path, |
&error)) { |
- LOG(ERROR) << "Dropping policy " << policy_name << " for " |
- << it->first.component_id |
- << " because it's not valid: " << error |
- << " at " << error_path; |
+ LOG(ERROR) << "Dropping policy " << policy_name << " of component " |
+ << it->first.component_id << " due to error at " |
+ << (error_path.empty() ? "root" : error_path) << ": " |
+ << error; |
map->Erase(policy_name); |
} |
} |