Function loterra_staking_contract::claim::claim_tokens[][src]

pub fn claim_tokens(
    storage: &mut dyn Storage,
    addr: CanonicalAddr,
    block: &BlockInfo,
    cap: Option<Uint128>
) -> StdResult<Uint128>
Expand description

This iterates over all mature claims for the address, and removes them, up to an optional cap. it removes the finished claims and returns the total amount of tokens to be released.