Directory cleanups and fix test
Modularise processing based on document type.

Read receipts from `@documentTypeName()`