Rename ...Dao -> ...Repository

This commit is contained in:
P0nk
2024-09-14 12:06:09 +02:00
parent abbec8120e
commit 08eeeb54dc
17 changed files with 103 additions and 103 deletions

View File

@@ -1,7 +1,7 @@
package service;
import client.Character;
import database.DaoException;
import database.DatabaseException;
import database.note.NoteDao;
import model.Note;
import net.packet.out.ShowNotesPacket;
@@ -52,7 +52,7 @@ public class NoteService {
try {
noteDao.save(note);
return true;
} catch (DaoException e) {
} catch (DatabaseException e) {
log.error("Failed to send note {}", note, e);
return false;
}
@@ -80,7 +80,7 @@ public class NoteService {
final List<Note> notes;
try {
notes = noteDao.findAllByTo(to);
} catch (DaoException e) {
} catch (DatabaseException e) {
log.error("Failed to find notes sent to chr name {}", to, e);
return Collections.emptyList();
}
@@ -101,7 +101,7 @@ public class NoteService {
public Optional<Note> delete(int noteId) {
try {
return noteDao.delete(noteId);
} catch (DaoException e) {
} catch (DatabaseException e) {
log.error("Failed to discard note with id {}", noteId, e);
return Optional.empty();
}