Fix the logic for the CollectLibs flag