모델 삭제할때 임시파일 경로 Null 처리
This commit is contained in:
@@ -82,6 +82,10 @@ public class ModelTrainMngService {
|
|||||||
throw new CustomApiException("NOT_FOUND", HttpStatus.NOT_FOUND, "모델 없음");
|
throw new CustomApiException("NOT_FOUND", HttpStatus.NOT_FOUND, "모델 없음");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (model.getRequestPath() == null) {
|
||||||
|
throw new CustomApiException("NOT_FOUND", HttpStatus.NOT_FOUND, "임시파일 경로 없음");
|
||||||
|
}
|
||||||
|
|
||||||
// ===== 2. 경로 생성 =====
|
// ===== 2. 경로 생성 =====
|
||||||
Path tmpBase = Path.of(symbolicDir).toAbsolutePath().normalize();
|
Path tmpBase = Path.of(symbolicDir).toAbsolutePath().normalize();
|
||||||
Path tmp = tmpBase.resolve(model.getRequestPath()).normalize();
|
Path tmp = tmpBase.resolve(model.getRequestPath()).normalize();
|
||||||
|
|||||||
Reference in New Issue
Block a user