fix map api

This commit is contained in:
Aiden McClelland
2021-09-21 17:22:51 -06:00
committed by Aiden McClelland
parent e9792f7afe
commit b7c8ee67bd

View File

@@ -244,10 +244,11 @@ impl<T: HasModel + Serialize + for<'de> Deserialize<'de>> OptionModel<T> {
F: FnOnce(T::Model) -> V,
U: Serialize + for<'de> Deserialize<'de>,
V: ModelFor<U>,
W: ModelFor<Option<U>>,
>(
self,
f: F,
) -> Model<Option<U>> {
) -> W {
Into::<JsonPointer>::into(f(self.0)).into()
}