From 955bdaa4381945dc8e1d34120ec26ed5089367cb Mon Sep 17 00:00:00 2001 From: Anton Romanov Date: Tue, 23 Apr 2019 13:55:59 +0400 Subject: [PATCH] fix repository method --- src/main/java/ru/ulstu/project/service/ProjectService.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/ru/ulstu/project/service/ProjectService.java b/src/main/java/ru/ulstu/project/service/ProjectService.java index e2feef4..115f5ae 100644 --- a/src/main/java/ru/ulstu/project/service/ProjectService.java +++ b/src/main/java/ru/ulstu/project/service/ProjectService.java @@ -67,7 +67,7 @@ public class ProjectService { project.setStatus(projectDto.getStatus() == null ? APPLICATION : projectDto.getStatus()); project.setTitle(projectDto.getTitle()); if (projectDto.getGrant() != null && projectDto.getGrant().getId() != null) { - project.setGrant(grantRepository.findOne(projectDto.getGrant().getId())); + project.setGrant(grantRepository.getOne(projectDto.getGrant().getId())); } project.setRepository(projectDto.getRepository()); project.setDeadlines(deadlineService.saveOrCreate(projectDto.getDeadlines()));