forked from akshay9/librephotos-mobile
-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
30 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,24 @@ | ||
import { | ||
buildAsyncState, | ||
buildAsyncActions, | ||
buildAsyncReducers, | ||
} from '@thecodingmachine/redux-toolkit-wrapper' | ||
import api from '@/Services' | ||
|
||
export default { | ||
initialState: buildAsyncState(), | ||
action: buildAsyncActions('album/fetchPeople', async (args, k) => { | ||
return await api | ||
.get('/persons/', { | ||
timeout: 10000, | ||
}) | ||
.then(response => { | ||
return response.data | ||
}) | ||
.catch(e => { | ||
console.log('Request Failed', e) | ||
return e | ||
}) | ||
}), | ||
reducers: buildAsyncReducers({ itemKey: 'albumPeople' }), // We do not want to modify some item by default | ||
} | ||
import { | ||
buildAsyncState, | ||
buildAsyncActions, | ||
buildAsyncReducers, | ||
} from '@thecodingmachine/redux-toolkit-wrapper' | ||
import api from '@/Services' | ||
|
||
export default { | ||
initialState: buildAsyncState(), | ||
action: buildAsyncActions('album/fetchPeople', async (args, k) => { | ||
return await api | ||
.get('/persons/', { | ||
timeout: 10000, | ||
}) | ||
.then(response => { | ||
return response.data | ||
}) | ||
.catch(e => { | ||
console.log('Request Failed', e) | ||
return e | ||
}) | ||
}), | ||
reducers: buildAsyncReducers({ itemKey: 'albumPeople' }), // We do not want to modify some item by default | ||
} |