Closed adirburke closed 5 years ago
It looks like I can not register with 6 injections, How can I work around this?
According to this - https://github.com/AliSoftware/Dip/wiki/runtime-arguments you can only use 6 runtime arguments $0...$5. So in order to use more than that you can create your own overload. Or you can call resolve() on a container instead of $x argument.
@idi888 please follow a comment in the documentation for register
methods, it has instructions for how to extend number of arguments.
Line of code
container.register { EmailService(emailConfiguration: $0, issueService: $1, configuration: $2, imageService: $3, roomService: $4, emailRepository: $5, gmailService: $6) as EmailServiceProtocol }
Cannot invoke 'register' with an argument list of type '((EmailConfiguration, IssueServiceProtocol, Configuration, IssueImagesServiceProtocol, RoomServiceProtocol, EmailRespositoryProtocol, GoogleServiceProtocol) -> EmailServiceProtocol)'