vw_small

Hardened fork of Vaultwarden (https://github.com/dani-garcia/vaultwarden) with fewer features.
git clone https://git.philomathiclife.com/repos/vw_small
Log | Files | Refs | README

commit 84e901b7d267591aca660e0bca7f0d0f620534d3
parent 19e671ff25bffa47424b5af44264c2c74c2cc84b
Author: Jan Jansen <jan.jansen@gdata.de>
Date:   Fri, 23 Jun 2023 08:26:45 +0200

add user to collection during creation

Signed-off-by: Jan Jansen <jan.jansen@gdata.de>

Diffstat:
Msrc/api/core/organizations.rs | 4++++
1 file changed, 4 insertions(+), 0 deletions(-)

diff --git a/src/api/core/organizations.rs b/src/api/core/organizations.rs @@ -424,6 +424,10 @@ async fn post_organization_collections( .await?; } + if headers.org_user.atype == UserOrgType::Manager && !headers.org_user.access_all { + CollectionUser::save(&headers.org_user.user_uuid, &collection.uuid, false, false, &mut conn).await?; + } + Ok(Json(collection.to_json())) }