Event spam in RewardsDistributor.claimRewards
The `RewardsDistributor` contract allows users to claim their rewards through the `claimRewards()` function. It does check to see whether or not the user has already claimed the rewards for a specific epoch that they are claiming for, but it does not check to see if the user has any associated rewards at all. This could lead to event `ClaimedRewards` being spammed by malicious users, especially on low gas chains.\\n```\\nfor (uint256 i = 0; i < epochNumbers.length; i++) {\\n    if (\\_claimedRewardsPerEpoch[shareId][epochNumbers[i]][\\_msgSender()]) revert AlreadyClaimed();\\n    \\_claimedRewardsPerEpoch[shareId][epochNumbers[i]][\\_msgSender()] = true;\\n    uint256 epochRewards = \\_availableReward(shareId, isDelegator, epochNumbers[i], \\_msgSender());\\n    SafeERC20.safeTransfer(rewardsToken, \\_msgSender(), epochRewards);\\n    emit ClaimedRewards(subjectType, subjectId, \\_msgSender(), epochNumbers[i], epochRewards);\\n```\\n
Add a check for rewards amounts being greater than 0.
```\\nfor (uint256 i = 0; i < epochNumbers.length; i++) {\\n    if (\\_claimedRewardsPerEpoch[shareId][epochNumbers[i]][\\_msgSender()]) revert AlreadyClaimed();\\n    \\_claimedRewardsPerEpoch[shareId][epochNumbers[i]][\\_msgSender()] = true;\\n    uint256 epochRewards = \\_availableReward(shareId, isDelegator, epochNumbers[i], \\_msgSender());\\n    SafeERC20.safeTransfer(rewardsToken, \\_msgSender(), epochRewards);\\n    emit ClaimedRewards(subjectType, subjectId, \\_msgSender(), epochNumbers[i], epochRewards);\\n```\\n