-
Notifications
You must be signed in to change notification settings - Fork 2
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
I ran into an issue similar to #9, but when the service is Request Scoped.
For example, using the existing can inject other providers into the factory test case within Loader.test.ts, but making the service definition like:
@Injectable({ scope: Scope.REQUEST })
class TestService {
test() {
return { path: "/path" };
}
}Yields:
[Nest] 74692 - 09/25/2025, 8:58:45 PM ERROR [ExceptionsHandler] TypeError: Receiver must be an instance of class DataloaderFactory
at DataLoader._batchLoadFn (/Users/george/Downloads/nestjs-dataloader/src/Dataloader.factory.ts:19:18)
at dispatchBatch (/Users/george/Downloads/nestjs-dataloader/node_modules/dataloader/index.js:288:27)
at /Users/george/Downloads/nestjs-dataloader/node_modules/dataloader/index.js:268:5
at processTicksAndRejections (node:internal/process/task_queues:85:11)Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working