Just look for the toplevel dir tag

"campaign_name" is not an existing attribute in the given config anymore.
An addon should only contain a single toplevel dir tag with the name of the addon anyway.
This commit is contained in:
Gunter Labes 2022-12-15 16:55:43 +01:00 committed by GitHub
parent 274c6567a4
commit 48fcaaba0e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -125,10 +125,11 @@ void find_translations(const config& base_dir, config& addon)
void add_license(config& cfg)
{
config& dir = cfg.find_child("dir", "name", cfg["campaign_name"]);
config& dir = cfg.child("dir");
// No top-level directory? Hm..
if(!dir) {
LOG_CS << "Could not find toplevel [dir] tag";
return;
}