may be neater to loop over `container.injections` once and create a map `{name: dependency}` and then just look them up, rather than this double loop