19 lines
335 B
JavaScript
19 lines
335 B
JavaScript
import axios from "axios";
|
|
|
|
const url = `https://devapi.benjamyn.love/migrations/`;
|
|
|
|
export const getMigrations = () => (dispatch) => {
|
|
axios
|
|
.get(url)
|
|
.then((response) => {
|
|
dispatch({
|
|
migs: response.data,
|
|
});
|
|
})
|
|
.catch((error) => {
|
|
this.setState({
|
|
error: true,
|
|
});
|
|
});
|
|
};
|