feature: Support single organization policy

This adds back-end support for the [single organization policy](https://bitwarden.com/help/article/policies/#single-organization).
This commit is contained in:
Adam Jones
2021-09-24 17:55:49 +02:00
parent 9930a0d752
commit d014eede9a
11 changed files with 97 additions and 13 deletions

View File

@@ -477,7 +477,7 @@ impl UserOrganization {
}}
}
pub fn find_by_user(user_uuid: &str, conn: &DbConn) -> Vec<Self> {
pub fn find_confirmed_by_user(user_uuid: &str, conn: &DbConn) -> Vec<Self> {
db_run! { conn: {
users_organizations::table
.filter(users_organizations::user_uuid.eq(user_uuid))