Browse Source

credential checker: ensure curator is active

Mokhtar Naamani 5 năm trước cách đây
mục cha
commit
3b96a01246
1 tập tin đã thay đổi với 3 bổ sung1 xóa
  1. 3 1
      src/lib.rs

+ 3 - 1
src/lib.rs

@@ -461,7 +461,9 @@ impl versioned_store_permissions::CredentialChecker<Runtime> for ContentWorkingG
                 {
                     if let content_wg::Principal::Curator(curator_id) = principal {
                         let curator = <content_wg::CuratorById<Runtime>>::get(curator_id);
-                        if curator.role_account == *account {
+                        if curator.role_account == *account
+                            && curator.stage == content_wg::CuratorRoleStage::Active
+                        {
                             return true;
                         }
                     }