diff options
author | HampusM <hampus@hampusmat.com> | 2023-09-17 13:08:23 +0200 |
---|---|---|
committer | HampusM <hampus@hampusmat.com> | 2023-09-17 13:08:23 +0200 |
commit | 3e3a853615e97ee7c3aef09736eae8170c6fd78e (patch) | |
tree | dec1ed4cb85868ea2931f072150e3cd9b0ab32aa /src/di_container | |
parent | 75ca777bbeb618e14b1cf8854ebb37b7a2c884b5 (diff) |
refactor: replace castable factory Fn impl with method
Diffstat (limited to 'src/di_container')
-rw-r--r-- | src/di_container/blocking/mod.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/di_container/blocking/mod.rs b/src/di_container/blocking/mod.rs index 702141a..09e7db1 100644 --- a/src/di_container/blocking/mod.rs +++ b/src/di_container/blocking/mod.rs @@ -215,7 +215,7 @@ impl DIContainer binding_kind: "factory", })?; - Ok(SomePtr::Factory(factory(self.clone()).into())) + Ok(SomePtr::Factory(factory.call(self.clone()).into())) } #[cfg(feature = "factory")] Providable::DefaultFactory(factory_binding) => { @@ -234,7 +234,7 @@ impl DIContainer binding_kind: "default factory", })?; - Ok(SomePtr::Transient(default_factory(self.clone())())) + Ok(SomePtr::Transient(default_factory.call(self.clone())())) } } } |