daostack / daostack/arc

add method that returns the organizationId given the avatar address

Open
#554 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
50
Forks
21
PR merge metrics
No merged PRs in 30d

Description

Two GenesisProtocol methods require an organizationId as an argument: `threshold` and `getBoostedProposalsCount`. However, the only way to obtain the organizationId is via `getProposalOrganization` which requires a proposalId. There should be a higher-level way to obtain the organizationId for a scheme.

The application should not be required to know how to compute the organizationId itself -- this would be extra unnecessary work for every application, extra documentation/training for Arc, and would cause duplication of internal contract logic that should be kept encapsulated within the contract.

It seems that if functions like `threshold` and `getBoostedProposalsCount` are now to be scoped to the organizationId, which is itself scoped to each scheme that is using the GP, then each scheme should expose a method that returns the organizationId.

Thus I propose that each proposal-generating scheme in Arc provide a method that returns the organizationId associated with it, given an avatar address as a singe argument.

This new method would be a part of `IntVoteInterface` and would be implemented in infra by `GenesisProtocol` and `AbsoluteVote`.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.