1
0
Fork 1
Spiegel von https://github.com/dani-garcia/vaultwarden.git synchronisiert 2024-11-25 05:40:29 +01:00

Fix org creation regresion

A previous PR added a field which isn't there on the initial creation of
an org. This PR fixes that.
Dieser Commit ist enthalten in:
BlackDex 2023-07-06 10:14:04 +02:00
Ursprung 4826ddca4c
Commit 08f37b9935
Es konnte kein GPG-Schlüssel zu dieser Signatur gefunden werden
GPG-Schlüssel-ID: 58C80A2AA6C765E1

Datei anzeigen

@ -106,7 +106,6 @@ struct OrgData {
CollectionName: String, CollectionName: String,
Key: String, Key: String,
Name: String, Name: String,
ExternalId: String,
Keys: Option<OrgKeyData>, Keys: Option<OrgKeyData>,
#[serde(rename = "PlanType")] #[serde(rename = "PlanType")]
_PlanType: NumberOrString, // Ignored, always use the same plan _PlanType: NumberOrString, // Ignored, always use the same plan
@ -170,7 +169,7 @@ async fn create_organization(headers: Headers, data: JsonUpcase<OrgData>, mut co
let org = Organization::new(data.Name, data.BillingEmail, private_key, public_key); let org = Organization::new(data.Name, data.BillingEmail, private_key, public_key);
let mut user_org = UserOrganization::new(headers.user.uuid, org.uuid.clone()); let mut user_org = UserOrganization::new(headers.user.uuid, org.uuid.clone());
let collection = Collection::new(org.uuid.clone(), data.CollectionName, Some(data.ExternalId)); let collection = Collection::new(org.uuid.clone(), data.CollectionName, None);
user_org.akey = data.Key; user_org.akey = data.Key;
user_org.access_all = true; user_org.access_all = true;