Added unmanaged empty directory detection