Skip to content

Commit

Permalink
Update contracts/airdrop/src/contract.rs
Browse files Browse the repository at this point in the history
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
  • Loading branch information
k-yang and coderabbitai[bot] authored Jan 3, 2024
1 parent 632fda3 commit ffb8d41
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions contracts/airdrop/src/contract.rs
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ pub fn query(deps: Deps, env: Env, msg: QueryMsg) -> StdResult<Binary> {
pub fn query_campaign(deps: Deps, _env: Env) -> StdResult<Binary> {
match CAMPAIGN.load(deps.storage) {
Ok(campaign) => return to_json_binary(&campaign),
Err(_) => return Err(StdError::generic_err("Campaign does not exist")),
Err(_) => return Err(StdError::generic_err("Failed to load campaign data")),
}
}

Expand All @@ -241,6 +241,6 @@ pub fn query_user_reward(
) -> StdResult<Binary> {
match USER_REWARDS.load(deps.storage, user_address) {
Ok(user_reward) => return to_json_binary(&user_reward),
Err(_) => return Err(StdError::generic_err("User reward does not exist")),
Err(_) => return Err(StdError::generic_err("Failed to load user reward data")),
};
}

0 comments on commit ffb8d41

Please sign in to comment.