Skip to content

Commit

Permalink
Alert on failed login or failed card validaton
Browse files Browse the repository at this point in the history
  • Loading branch information
Anthony Herco committed Dec 5, 2017
1 parent bb6de58 commit 25e34b1
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/scenes/Main/scenes/Bank/services/middleware.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ const cardMiddleware = store => next => action => {
/* eslint-disable */
console.log('VALIDATE_ADD_CARD fail');
/* eslint-enable */
return;
return alert('Invalid url');
}
/* eslint-disable */
console.log('VALIDATE_ADD_CARD success');
Expand Down
2 changes: 1 addition & 1 deletion src/scenes/Main/services/middleware.js
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ const bankMiddleware = store => next => action => {
break;

case UPDATE_ACTIVE_BANK:
return store.dispatch(getCards(action.id));
return next(getCards(action.id));

default:
break;
Expand Down
2 changes: 1 addition & 1 deletion src/services/middleware.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ const accountMiddleware = store => next => action => {
/* eslint-disable */
console.log('LOGIN_USER fail');
/* eslint-enable */
return;
return alert('Invalid email or password');
}
/* eslint-disable */
console.log('LOGIN_USER success');
Expand Down

0 comments on commit 25e34b1

Please sign in to comment.