ЛР5 вроде готово
This commit is contained in:
parent
7512de70c2
commit
157ba0f38b
BIN
data.mv.db
BIN
data.mv.db
Binary file not shown.
@ -74,7 +74,6 @@ public class FilmService {
|
|||||||
if (film == null) {
|
if (film == null) {
|
||||||
throw new EntityNotFoundException(String.format("Film with id [%s] is not found", filmId));
|
throw new EntityNotFoundException(String.format("Film with id [%s] is not found", filmId));
|
||||||
}
|
}
|
||||||
film.removeGenres();
|
|
||||||
for(Long genreId : genreIds) {
|
for(Long genreId : genreIds) {
|
||||||
final Genre genre = genreService.findGenre(genreId);
|
final Genre genre = genreService.findGenre(genreId);
|
||||||
film.addGenre(genre);
|
film.addGenre(genre);
|
||||||
|
Loading…
Reference in New Issue
Block a user