Skip to content

Commit

Permalink
refactor: Todo에서 delete 메소드 내부 동작으로 변경
Browse files Browse the repository at this point in the history
  • Loading branch information
jucheolkang committed Jan 25, 2024
1 parent 45fb635 commit f32b746
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ public void changeCheck(Long id) {
public void delete(Long id) {
Todo todo = existId(id);
checkDeleteStatus(todo);
todo.delete(true);
todo.delete();
}

private void checkDeleteStatus(Todo todo) {
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/org/idiot/yesslave/todo/domain/Todo.java
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,8 @@ public void changeCheck(boolean todoCheck) {
public void update(String todo) {
this.todo = todo;
}
public void delete (boolean delete) {
this.delete = delete;
public void delete () {
delete = true;
}

}

0 comments on commit f32b746

Please sign in to comment.