@jetthai/cuora 1.1.297 → 1.1.299

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -74,12 +74,14 @@ export default function (request) {
74
74
  },
75
75
  checking: {
76
76
  always: [
77
+ { target: 'claimAmountLimitReached', cond: 'isClaimAmountLimitReached' },
77
78
  { target: 'claimExhausted', cond: 'isClaimExhausted' },
78
79
  { target: 'insufficientAmount', cond: 'isInsufficientAmount' },
79
80
  { target: 'claimEnable', cond: 'isClaimEnable' },
80
81
  { target: 'cantEstimate' },
81
82
  ],
82
83
  },
84
+ claimAmountLimitReached: {},
83
85
  claimExhausted: {},
84
86
  insufficientAmount: {},
85
87
  claimEnable: {
@@ -161,6 +163,10 @@ export default function (request) {
161
163
  return parseInt(`${currentTime}`) - parseInt(`${lastEstimateTime}`) > fiveMinutes
162
164
  }
163
165
  },
166
+ isClaimAmountLimitReached: (context, event) => {
167
+ const { collectAvailable } = context
168
+ return !collectAvailable
169
+ },
164
170
  isClaimExhausted: (context, event) => {
165
171
  const { collectAvailable, remainingCount, dailyRedemptionLimit } = context
166
172
  return !collectAvailable && parseInt(`${remainingCount}`) === parseInt(`${dailyRedemptionLimit}`)