We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 854caa4 commit d44a19bCopy full SHA for d44a19b
1 file changed
lib/agent/lockup/calculateCumulativeHoldersRewardAmount.ts
@@ -0,0 +1,18 @@
1
+import { Provider } from '@ethersproject/abstract-provider'
2
+import { getLockupContract } from './common'
3
+
4
+type Options = {
5
+ readonly provider: Provider
6
+ readonly propertyAddress: string
7
+}
8
9
+export const calculateCumulativeHoldersRewardAmount = async (
10
+ options: Options
11
+): Promise<string | undefined> => {
12
+ const lockupContract = await getLockupContract(options.provider)
13
+ return lockupContract
14
+ ? lockupContract.calculateCumulativeHoldersRewardAmount(
15
+ options.propertyAddress
16
+ )
17
+ : undefined
18
0 commit comments