Browse Source

add square finished action creator

pull/8/head
Tim Glasgow 2 years ago
parent
commit
900ee7f4d6
  1. 11
      squarenotsquare/src/redux/actions/UserActions.js

11
squarenotsquare/src/redux/actions/UserActions.js

@ -1,5 +1,5 @@
import { squareNav } from "../../navigation/SquareNav";
import { SQUARE_START } from "../types/SystemTypes";
import { SQUARE_FINISHED, SQUARE_START } from "../types/UserTypes";
export function squareStartPressed() {
return (dispatch) => {
@ -8,4 +8,13 @@ export function squareStartPressed() {
type: SQUARE_START
});
}
}
export function squareFinished(score) {
return (dispatch) => {
squareNav('Score');
dispatch({
type: SQUARE_FINISHED
});
}
}
Loading…
Cancel
Save