Support both single-object and lists when reading handlers and sources from YAML files in a directory.