aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlex Auvolat <alex@adnab.me>2022-02-02 17:12:48 +0100
committerAlex Auvolat <alex@adnab.me>2022-02-02 17:12:48 +0100
commitae2f32baf143ecc312a54496f1b0df1f47af79d4 (patch)
tree97d6637a1ef903f851872a5d1738917eb63c8090
parentf67029ce2af2f8870836d5bb908254d7fdbbe71b (diff)
downloadgarage-ae2f32baf143ecc312a54496f1b0df1f47af79d4.tar.gz
garage-ae2f32baf143ecc312a54496f1b0df1f47af79d4.zip
Hide deleted key in bucket info (fix #211)
-rw-r--r--src/garage/cli/util.rs3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/garage/cli/util.rs b/src/garage/cli/util.rs
index 61401e4c..7d496507 100644
--- a/src/garage/cli/util.rs
+++ b/src/garage/cli/util.rs
@@ -153,6 +153,9 @@ pub fn print_bucket_info(bucket: &Bucket, relevant_keys: &HashMap<String, Key>)
println!("\nAuthorized keys:");
let mut table = vec![];
for (k, perm) in p.authorized_keys.items().iter() {
+ if !perm.is_any() {
+ continue;
+ }
let rflag = if perm.allow_read { "R" } else { " " };
let wflag = if perm.allow_write { "W" } else { " " };
let oflag = if perm.allow_owner { "O" } else { " " };