forked from external/yambar
oarticles: don't assume particle content is a dictionary
This is done by having each particle implement a top-level verifier function.
This commit is contained in:
parent
9944a8f972
commit
8bc6a0b783
8 changed files with 77 additions and 27 deletions
|
@ -292,8 +292,10 @@ conf_verify_particle_dictionary(keychain_t *chain, const struct yml_node *node)
|
|||
return false;
|
||||
}
|
||||
|
||||
assert(info->verify_conf != NULL);
|
||||
|
||||
chain_push(chain, particle_name);
|
||||
if (!conf_verify_dict(chain, values, info->attrs))
|
||||
if (!info->verify_conf(chain, values))
|
||||
return false;
|
||||
|
||||
chain_pop(chain);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue