This commit is contained in:
JMARyA 2024-09-13 22:10:11 +02:00
parent b0bae64efc
commit 58150002e6
Signed by: jmarya
GPG key ID: 901B2ADDF27C2263

View file

@ -130,11 +130,11 @@ macro_rules! reference_of {
($model:ident, $id:ident) => {{
$model::get_partial($id, serde_json::json!({}))
.await
.map(|x| x.reference())
.map(|x| mongod::Referencable::reference(&x))
}};
($model:ident, $id:literal) => {{
$model::get_partial($id, serde_json::json!({}))
.await
.map(|x| x.reference())
.map(|x| mongod::Referencable::reference(&x))
}};
}