I'm trying to use moduleRef.resolve to create a provider that is an exported in another module that is imported in the current module.
I'm getting the error
Error: Nest could not find [Provider] element (this provider does not exist in the current context)
I followed the discussion here https://github.com/nestjs/nest/issues/5487 and the suggested fix does not work.
Any ideas on how to get this to work? The last person on that thread shares my confusion. Why am I able to import the provider with normal dependency injection but not with moduleRef.resolve?