Added support for noinject/noinfer, nested document context