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 f1161c65fb67c2f54a7c20b0f7aafdc2f9cd0af1
parent 50eeb4f651b3e320d647bd6830097765ba3788eb
Author: Daniel GarcĂ­a <dani-garcia@users.noreply.github.com>
Date:   Tue,  8 Jan 2019 14:05:05 +0100

Make sure an invitation is created when reinviting

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

diff --git a/src/api/core/organizations.rs b/src/api/core/organizations.rs @@ -545,8 +545,9 @@ fn reinvite_user(org_id: String, user_org: String, headers: AdminHeaders, conn: Some(user) => user, None => err!("User not found."), }; - - Invitation::take(&user.email, &conn); + + let mut invitation = Invitation::new(user.email.clone()); + invitation.save(&conn)?; let org_name = match Organization::find_by_uuid(&org_id, &conn) { Some(org) => org.name,