This now checks from the top to the bottom that all objects referenced by a
I'm opening the diff as a correctness first approach. Did not refactor the
common code yet.
Also i believe i'm missing the nested directory check scenario (but that's not really a blocker).
Related to T2483
Depends on D3502