public async Task <Photo> UploadPhotoAsync(Vehicle vehicle, IFormFile file, string uploadsFolderPath) { var fileName = await photoStorage.StoreAsync(uploadsFolderPath, file); var photo = new Photo { FileName = fileName }; vehicle.Photos.Add(photo); await unitOfWork.CompleteAsync(); return(photo); }