Skip to content

Commit efbb162

Browse files
authored
Position assign proxy should show all positions for convenience (#874)
1 parent 6b8b3d6 commit efbb162

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

src/features/governance/AssignProxyScreen.tsx

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,6 @@ export const AssignProxyScreen = () => {
5151
const { wallet, position } = route.params
5252
const { t } = useTranslation()
5353
const [proxyWallet, setProxyWallet] = useState(wallet)
54-
const positionKey = usePublicKey(position)
5554
const { loading, positions, refetch, mint } = useGovernance()
5655
const networks = useMemo(() => {
5756
return [
@@ -64,13 +63,9 @@ export const AssignProxyScreen = () => {
6463
const unproxiedPositions = useMemo(
6564
() =>
6665
positions?.filter(
67-
(p) =>
68-
!p.proxy ||
69-
(p.proxy.nextVoter.equals(PublicKey.default) &&
70-
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
71-
(!positionKey || p.pubkey.equals(positionKey!))),
66+
(p) => !p.proxy || p.proxy.nextVoter.equals(PublicKey.default),
7267
) || [],
73-
[positions, positionKey],
68+
[positions],
7469
)
7570
const [selectedPositions, setSelectedPositions] = useState<Set<string>>(
7671
new Set<string>([position].filter(truthy)),

0 commit comments

Comments
 (0)