Skip to content

Commit

Permalink
Fix bug where no voting power when you have proxy voting power (#817)
Browse files Browse the repository at this point in the history
* Fix bug where no voting power when you have proxy voting power

* Lint

* Bump marketing
  • Loading branch information
ChewingGlass authored Oct 17, 2024
1 parent e9a4af5 commit 99858ad
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 10 deletions.
12 changes: 6 additions & 6 deletions ios/HeliumWallet.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -1079,7 +1079,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 2.9.0;
MARKETING_VERSION = 2.10.0;
ONLY_ACTIVE_ARCH = NO;
OTHER_LDFLAGS = (
"$(inherited)",
Expand Down Expand Up @@ -1117,7 +1117,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 2.9.0;
MARKETING_VERSION = 2.10.0;
OTHER_LDFLAGS = (
"$(inherited)",
"-ObjC",
Expand Down Expand Up @@ -1303,7 +1303,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 2.9.0;
MARKETING_VERSION = 2.10.0;
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES;
OTHER_SWIFT_FLAGS = "$(inherited) -D EXPO_CONFIGURATION_DEBUG";
Expand Down Expand Up @@ -1348,7 +1348,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 2.9.0;
MARKETING_VERSION = 2.10.0;
MTL_FAST_MATH = YES;
OTHER_SWIFT_FLAGS = "$(inherited) -D EXPO_CONFIGURATION_RELEASE";
PRODUCT_BUNDLE_IDENTIFIER = com.helium.wallet.app.OneSignalNotificationServiceExtension;
Expand Down Expand Up @@ -1396,7 +1396,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 2.9.0;
MARKETING_VERSION = 2.10.0;
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES;
OTHER_SWIFT_FLAGS = "$(inherited) -D EXPO_CONFIGURATION_DEBUG";
Expand Down Expand Up @@ -1445,7 +1445,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 2.9.0;
MARKETING_VERSION = 2.10.0;
MTL_FAST_MATH = YES;
OTHER_SWIFT_FLAGS = "$(inherited) -D EXPO_CONFIGURATION_RELEASE";
PRODUCT_BUNDLE_IDENTIFIER = com.helium.wallet.app.HeliumWalletWidget;
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "helium-wallet",
"version": "2.9.0",
"version": "2.10.0",
"private": true,
"scripts": {
"postinstall": "patch-package && ./node_modules/.bin/rn-nodeify --hack --install && npx jetify",
Expand Down
4 changes: 2 additions & 2 deletions src/features/governance/ProposalScreen.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ export const ProposalScreen = () => {
)
const { anchorProvider } = useSolana()
const { walletSignBottomSheetRef } = useWalletSign()
const { mint, loading, amountLocked } = useGovernance()
const { mint, loading, votingPower } = useGovernance()
const handleBrowseVoters = useCallback(() => {
navigation.navigate('VotersScreen', {
mint: mint.toBase58(),
Expand Down Expand Up @@ -269,7 +269,7 @@ export const ProposalScreen = () => {
))

const completed = endTs && endTs.toNumber() <= Date.now().valueOf() / 1000
const noVotingPower = !loading && (!amountLocked || amountLocked.isZero())
const noVotingPower = !loading && (!votingPower || votingPower.isZero())
const voted = !voting && voteWeights?.some((n) => n.gt(new BN(0)))
const showVoteResults =
derivedState !== 'cancelled' &&
Expand Down
2 changes: 1 addition & 1 deletion src/features/governance/VotingPowerCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ export const VotingPowerCard = ({
if (onPress) await onPress(mint)
}, [onPress, mint])

const noVotingPower = !loading && (!amountLocked || amountLocked.isZero())
const noVotingPower = !loading && (!votingPower || votingPower.isZero())

const renderCard = (compact = false) => {
if (loading) return <VotingPowerCardSkeleton />
Expand Down

0 comments on commit 99858ad

Please sign in to comment.