Fr] implement add and search methods for phone book interface #30#56
Fr] implement add and search methods for phone book interface #30#56DenysBurduzhan wants to merge 4 commits intomainfrom
Conversation
Coverage summary from CodacySee diff coverage on Codacy
Coverage variation details
Coverage variation is the difference between the coverage for the head and common ancestor commits of the pull request branch: Diff coverage details
Diff coverage is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified: See your quality gate settings Change summary preferencesCodacy stopped sending the deprecated coverage status on June 5th, 2024. Learn more |
| default void saveAll(List<ContactDto> contacts) throws IOException { | ||
| objectMapper.writeValue(new File("demo.st"), contacts); | ||
| } | ||
| ; |
There was a problem hiding this comment.
ℹ️ Codacy found a minor Code Style issue: ';' should be separated from previous line.
The issue identified by the Checkstyle linter is that there is an unnecessary semicolon (;) on its own line, which is not properly separated from the previous line. In Java, a semicolon is used to terminate statements, and having it on a separate line without any context is not a standard practice and can lead to confusion.
To fix this issue, simply remove the semicolon from its own line. Here’s the suggested change:
| ; | |
| } |
This comment was generated by an experimental AI tool.
dRaider-bitrek
left a comment
There was a problem hiding this comment.
Метод "add" зараз не зберігає новий контакт.
| List<ContactDto> contacts = findAll(); | ||
| contacts.add(contactDto); | ||
| saveAll(contacts); | ||
| } |
There was a problem hiding this comment.
тут треба перевірити ContactDto.id та створити новий унікальний якщо id = 0;
Тобто не зовсім тут, це інтерфейс.
| .fullName(contactDto.getFullName()) | ||
| .phones(List.of(String.valueOf(contactDto.getPhones()))) | ||
| .emails(List.of(String.valueOf(contactDto.getEmails()))) | ||
| .build(); |
There was a problem hiding this comment.
Не зовсім зрозумів що ти планував. Ти вже отримуєш ContactDto його треба зберегти до файлу за допомогою ContactDtoRepository
No description provided.