@@ -10,25 +10,16 @@ export const requestLogin = (user, authEndpoint, redirectUri, clientCredentials)
1010 clientCredentials
1111} ) ;
1212
13- export const notifyLoginFail = ( ) => ( {
14- type : USER_LOGIN_FAILED
15- } ) ;
13+ export const notifyLoginFail = ( ) => ( { type : USER_LOGIN_FAILED } ) ;
1614
17- export const notifyLoginSucceeded = ( ) => ( {
18- type : USER_LOGIN_SUCCEEDED
19- } ) ;
15+ export const notifyLoginSucceeded = ( ) => ( { type : USER_LOGIN_SUCCEEDED } ) ;
2016
2117export const USER_FETCH_TOKEN_REQUESTED = 'USER_FETCH_TOKEN_REQUESTED' ;
2218export const USER_FETCH_TOKEN_SUCCEEDED = 'USER_TOKEN_SUCCEEDED' ;
2319
24- export const requestFetchToken = ( ) => ( {
25- type : USER_FETCH_TOKEN_REQUESTED
26- } ) ;
20+ export const requestFetchToken = ( ) => ( { type : USER_FETCH_TOKEN_REQUESTED } ) ;
2721
28- export const notifyFetchTokenSucceeded = token => ( {
29- type : USER_FETCH_TOKEN_SUCCEEDED ,
30- token
31- } ) ;
22+ export const notifyFetchTokenSucceeded = token => ( { type : USER_FETCH_TOKEN_SUCCEEDED , token} ) ;
3223
3324export const USER_FETCH_REFRESH_TOKEN_REQUESTED = 'USER_FETCH_REFRESH_TOKEN_REQUESTED' ;
3425export const USER_FETCH_REFRESH_TOKEN_SUCCEEDED = 'USER_FETCH_REFRESH_TOKEN_SUCCEEDED' ;
@@ -40,9 +31,7 @@ export const requestFetchRefreshToken = (authEndpoint, clientId, clientSecret) =
4031 clientSecret
4132} ) ;
4233
43- export const notifyFetchRefreshTokenSucceeded = ( ) => ( {
44- type : USER_FETCH_REFRESH_TOKEN_SUCCEEDED
45- } ) ;
34+ export const notifyFetchRefreshTokenSucceeded = ( ) => ( { type : USER_FETCH_REFRESH_TOKEN_SUCCEEDED } ) ;
4635
4736export const USER_REFRESH_ACCESS_TOKEN_REQUESTED = 'USER_REFRESH_ACCESS_TOKEN_REQUESTED' ;
4837export const USER_REFRESH_ACCESS_TOKEN_SUCCEEDED = 'USER_REFRESH_ACCESS_TOKEN_SUCCEEDED' ;
@@ -54,41 +43,32 @@ export const requestFetchRefreshAccessToken = (authEndpoint, clientId, clientSec
5443 clientSecret
5544} ) ;
5645
57- export const notifyRefreshAccessToken = ( ) => ( {
58- type : USER_REFRESH_ACCESS_TOKEN_SUCCEEDED
59- } ) ;
46+ export const notifyRefreshAccessToken = ( ) => ( { type : USER_REFRESH_ACCESS_TOKEN_SUCCEEDED } ) ;
6047
6148export const LAST_USER_LOGGED_REQUESTED = 'LAST_USER_LOGGED_REQUESTED' ;
6249export const LAST_USER_LOGGED_SUCCEEDED = 'LAST_USER_LOGGED_SUCCEEDED' ;
6350
64- export const requestLastUserLogged = ( ) => ( {
65- type : LAST_USER_LOGGED_REQUESTED
66- } ) ;
51+ export const requestLastUserLogged = ( ) => ( { type : LAST_USER_LOGGED_REQUESTED } ) ;
6752
68- export const receiveLastUserLogged = lastUserLogged => ( {
69- type : LAST_USER_LOGGED_SUCCEEDED ,
70- lastUserLogged
71- } ) ;
53+ export const receiveLastUserLogged = lastUserLogged => ( { type : LAST_USER_LOGGED_SUCCEEDED , lastUserLogged} ) ;
7254
7355export const CLEAR_USER_DATA_REQUESTED = 'CLEAR_USER_DATA_REQUESTED' ;
7456export const CLEAR_USER_DATA_SUCCEEDED = 'CLEAR_USER_DATA_SUCCEEDED' ;
7557
76- export const requestClearUserData = ( ) => ( {
77- type : CLEAR_USER_DATA_REQUESTED
78- } ) ;
58+ export const requestClearUserData = ( ) => ( { type : CLEAR_USER_DATA_REQUESTED } ) ;
7959
80- export const notifyDataCleared = ( ) => ( {
81- type : CLEAR_USER_DATA_SUCCEEDED
82- } ) ;
60+ export const notifyDataCleared = ( ) => ( { type : CLEAR_USER_DATA_SUCCEEDED } ) ;
8361
8462export const CHANGE_USER_REQUESTED = 'CHANGE_USER_REQUESTED' ;
8563export const CHANGE_USER_SUCCEEDED = 'CHANGE_USER_SUCCEEDED' ;
8664
87- export const requestChangeUser = userProfile => ( {
88- type : CHANGE_USER_REQUESTED ,
89- userProfile
90- } ) ;
65+ export const requestChangeUser = userProfile => ( { type : CHANGE_USER_REQUESTED , userProfile} ) ;
9166
92- export const userChanged = ( ) => ( {
93- type : CHANGE_USER_SUCCEEDED
94- } ) ;
67+ export const userChanged = ( ) => ( { type : CHANGE_USER_SUCCEEDED } ) ;
68+
69+ export const FETCH_CURRENT_USER_REQUESTED = 'FETCH_CURRENT_USER_REQUESTED' ;
70+ export const FETCH_CURRENT_USER_SUCCEEDED = 'FETCH_CURRENT_USER_SUCCEEDED' ;
71+
72+ export const requestFetchCurrentUser = ( ) => ( { type : FETCH_CURRENT_USER_REQUESTED } ) ;
73+
74+ export const receiveCurrentUser = user => ( { type : FETCH_CURRENT_USER_SUCCEEDED , user} ) ;
0 commit comments