Skip to content

Commit

Permalink
lint: comply with rules
Browse files Browse the repository at this point in the history
  • Loading branch information
alexruzenhack committed Sep 5, 2024
1 parent e5c0a2a commit 3f06ed1
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/sagas/helpers.js
Original file line number Diff line number Diff line change
Expand Up @@ -352,10 +352,11 @@ export function* progressiveRetryRequest(request, maxRetries = MAX_RETRIES) {
* @param {Object} effect The targeted effect.
* @param {(error) => void} onError The error handling effect,
* which receives the error object as first argument.
*
*
* @returns An anonymous effect.
*/
export function safeEffect(effect, onError) {
// eslint-disable-next-line func-names
return function* (payload) {
try {
yield call(effect, payload);
Expand All @@ -364,4 +365,3 @@ export function safeEffect(effect, onError) {
}
}
}

5 changes: 4 additions & 1 deletion src/sagas/nanoContract.js
Original file line number Diff line number Diff line change
Expand Up @@ -450,7 +450,10 @@ export function* requestBlueprintInfo({ payload }) {
export function* saga() {
yield all([
debounce(500, [[types.START_WALLET_SUCCESS, types.NANOCONTRACT_INIT]], init),
takeEvery(types.NANOCONTRACT_REGISTER_REQUEST, safeEffect(registerNanoContract, registerNanoContractOnError)),
takeEvery(
types.NANOCONTRACT_REGISTER_REQUEST,
safeEffect(registerNanoContract, registerNanoContractOnError)
),
takeEvery(types.NANOCONTRACT_HISTORY_REQUEST, requestHistoryNanoContract),
takeEvery(types.NANOCONTRACT_UNREGISTER_REQUEST, unregisterNanoContract),
takeEvery(types.NANOCONTRACT_ADDRESS_CHANGE_REQUEST, requestNanoContractAddressChange),
Expand Down

0 comments on commit 3f06ed1

Please sign in to comment.