Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix group issue in send_invite #5321

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

stefan0xC
Copy link
Contributor

As pointed out in #5320 we have a small bug in this call:

For example I noticed that we are passing the wrong id here:

let mut group_entry = GroupUser::new(String::from(group), user.uuid.clone());

Because in contrast to CollectionUser the GroupUser::new actually expects a different id:

pub fn new(groups_uuid: String, users_organizations_uuid: String) -> Self {

This was probably overlooked because it's not a major issue when a user is not correctly invited to a group and it only shows up as a small warning in the logs:

[2024-12-22 21:23:47.022][request][INFO] POST /api/organizations/152bd996-19f9-40ee-b991-e52333a7e719/users/invite
[2024-12-22 21:23:47.031][vaultwarden::db::models::group][WARN] User could not be found!
[2024-12-22 21:23:48.082][response][INFO] (send_invite) POST /api/organizations/<org_id>/users/invite => 200 OK

Since reviewing my other PR will probably take a while this is a separate fix to address this one issue I found and remembered.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant