Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Prevent storing empty config files as loot #11076
This PR prevents the
Before this PR, this module would store every config file, regardless of whether it existed, and regardless of whether it was empty (ie, permission denied). This was mitigated in part by a regex for
In some instances, it may be useful to know that a config file existed, but was empty. However, this is rare, and the existing implementation also failed in this regard, due to the aforementioned shortcomings in the regex. For this reason, I argue that this PR is an improvement.
Worse, the loot is stored with the generic name
This PR also includes some minor style changes.
I didn't bother to test with a database. It turns out the config file names are also stored if a database is connected:
Fixing the filenames would make a bit of a mess of this output:
I'm not sure how important the loot
Perhaps it would make more sense to modify the