We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 6905923 commit 6874760Copy full SHA for 6874760
1 file changed
Sources/Resolve.swift
@@ -253,7 +253,7 @@ extension DependencyContainer {
253
254
//if no definition registered for exact type try to find type-forwarding definition that can resolve the type
255
//that will actually happen only when resolving optionals
256
- if definitions.filter({ $0.0.type == key.type }).isEmpty {
+ guard definitions.contains(where: { $0.0.type == key.type }) else {
257
return typeForwardingDefinition(forKey: key)
258
}
259
return nil
0 commit comments