diff options
author | Felix <me@nutomic.com> | 2020-04-17 17:33:55 +0200 |
---|---|---|
committer | Felix <me@nutomic.com> | 2020-04-17 17:33:55 +0200 |
commit | c5ced6fa5e0a5f80c9e58c3a4bf199434194195a (patch) | |
tree | 37ac9e7276934fb2f812e73bd05c6b61135ba771 /server/src/apub/user.rs | |
parent | 8908c8b1840f64f0bc82e37437703afed419f3f9 (diff) |
Added documentation for most functions
Diffstat (limited to 'server/src/apub/user.rs')
-rw-r--r-- | server/src/apub/user.rs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/server/src/apub/user.rs b/server/src/apub/user.rs index d10093d4..b5a81911 100644 --- a/server/src/apub/user.rs +++ b/server/src/apub/user.rs @@ -22,6 +22,7 @@ pub struct UserQuery { user_name: String, } +// Turn a Lemmy user into an ActivityPub person and return it as json. pub async fn get_apub_user( info: Path<UserQuery>, db: web::Data<Pool<ConnectionManager<PgConnection>>>, @@ -64,6 +65,7 @@ pub async fn get_apub_user( } impl UserForm { + /// Parse an ActivityPub person received from another instance into a Lemmy user. pub fn from_person(person: &PersonExt) -> Result<Self, Error> { let oprops = &person.base.base.object_props; let aprops = &person.base.extension; |