Skip to content

Commit

Permalink
update for ci passing?
Browse files Browse the repository at this point in the history
  • Loading branch information
elhagen13 committed Nov 29, 2023
1 parent 0225c9f commit a15ccd4
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 8 deletions.
2 changes: 2 additions & 0 deletions packages/studywell-frontend/src/components/timer/Timer.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ function Timer(props) {
}, 1000);
}
return () => clearInterval(timerRef.current);
// eslint-disable-next-line
}, [timerOn, minutes, seconds]);

function startTimer() {
Expand Down Expand Up @@ -59,6 +60,7 @@ function Timer(props) {
if (timerDone) {
navigateToMain();
}
// eslint-disable-next-line
}, [timerDone]);

return (
Expand Down
13 changes: 5 additions & 8 deletions packages/studywell-frontend/src/pages/MainScreen.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,6 @@ import "./Page.css";
function MainScreen() {
const [tasks, setTasks] = useState([]);

// function removeTask(index) {
// const updated = tasks.filter((task, i) => {
// return i !== index;
// });
// setTasks(updated);
// }
function deleteUser(_id) {
const promise = fetch(`http://localhost:8000/tasks/${_id}`, {
method: "DELETE",
Expand All @@ -23,6 +17,8 @@ function MainScreen() {

return promise;
}

// eslint-disable-next-line
function removeTask(index) {
const taskId = tasks[index]._id;
deleteUser(taskId)
Expand Down Expand Up @@ -50,7 +46,8 @@ function MainScreen() {
console.log(promise);
return promise;
}


// eslint-disable-next-line
function updateList(task) {
postUser(task)
.then((res) => {
Expand All @@ -68,7 +65,7 @@ function MainScreen() {
const promise = fetch("http://localhost:8000/tasks");
return promise;
}

useEffect(() => {
fetchTasks()
.then((res) => res.json())
Expand Down

0 comments on commit a15ccd4

Please sign in to comment.