Skip to content

Commit

Permalink
fixup! fix,feat(postbuildstepper): typo in cdunster, add trusted user…
Browse files Browse the repository at this point in the history
…s per-org
  • Loading branch information
steveej committed Dec 16, 2024
1 parent 0cfa821 commit 668e23b
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions applications/postbuildstepper/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -321,6 +321,8 @@ pub mod business {
),
];

let org = org.to_lowercase();

let mut trusted_owners =
HashSet::<String>::from_iter(TRUSTED_OWNERS.iter().map(|s| s.to_lowercase()));
trusted_owners.extend(
Expand All @@ -332,13 +334,13 @@ pub mod business {
)
},
))
.get(org)
.get(&org)
.cloned()
.unwrap_or_default(),
);
let owner_is_trusted = owners.is_subset(&trusted_owners);
if !owner_is_trusted {
bail!("{owners:?} are *NOT* trusted!");
bail!("{owners:?} are *NOT* among trusted users for {org}: {trusted_owners:?}");
}
info!("owners {owners:?} are trusted! proceeding.");

Expand Down

0 comments on commit 668e23b

Please sign in to comment.