From 51e1491b63827548c53697052566cfdaddafc844 Mon Sep 17 00:00:00 2001 From: Megha-Dev-19 Date: Tue, 12 Mar 2024 20:48:19 +0530 Subject: [PATCH] bug fixes --- apps/astraplusplus/widget/CreateDAO/Step6.jsx | 2 +- apps/astraplusplus/widget/DAO/Settings/index.jsx | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/apps/astraplusplus/widget/CreateDAO/Step6.jsx b/apps/astraplusplus/widget/CreateDAO/Step6.jsx index d7cf232..a09baa6 100644 --- a/apps/astraplusplus/widget/CreateDAO/Step6.jsx +++ b/apps/astraplusplus/widget/CreateDAO/Step6.jsx @@ -24,7 +24,7 @@ State.init({ function onGroupChange(name) { const item = initialAnswers.policy.roles.find((i) => i.name === name); - const voteWeight = item?.vote_policy.threshold ?? [1, 2]; + const voteWeight = item?.vote_policy?.add_bounty?.threshold ?? [1, 2]; State.update({ selectedGroup: name, voteWeight: parseInt((voteWeight?.[0] / voteWeight?.[1]) * 100), diff --git a/apps/astraplusplus/widget/DAO/Settings/index.jsx b/apps/astraplusplus/widget/DAO/Settings/index.jsx index c0cb9b8..b5dc519 100644 --- a/apps/astraplusplus/widget/DAO/Settings/index.jsx +++ b/apps/astraplusplus/widget/DAO/Settings/index.jsx @@ -52,7 +52,8 @@ const hasPermission = (proposalKind) => { if (roleObj) { return ( roleObj.permissions.includes(`${proposalKind}:*`) || - roleObj.permissions.includes("*:*") + roleObj.permissions.includes("*:*") || + roleObj.permissions.includes(`${proposalKind}:AddProposal`) ); } else { return false;