Added sort to getRepos action

This commit is contained in:
Camerin Figueroa 2022-02-09 23:58:43 -05:00
parent 15aae4ccf5
commit 2f7b57333c
1 changed files with 1 additions and 1 deletions

View File

@ -14,7 +14,7 @@ export const getUser = (username) => async (dispatch, getState) => {
}; };
export const getRepos = (username) => async (dispatch, getState) => { export const getRepos = (username) => async (dispatch, getState) => {
const response = await github.get(`/users/${username}/repos`); // axios request for repositories const response = await github.get(`/users/${username}/repos`, {params: {sort: 'updated'}}); // axios request for repositories
dispatch({ dispatch({
type: 'GET_REPOS', type: 'GET_REPOS',