Detect unmanged paths

Hi Jon,
consider these changes to your PR.