Skip to content

Commit 4aee759

Browse files
committed
Fixing file issue with none pdf documents.
1 parent 27fb6cf commit 4aee759

File tree

1 file changed

+2
-2
lines changed
  • eFormAPI/Plugins/BackendConfiguration.Pn/BackendConfiguration.Pn/Controllers

1 file changed

+2
-2
lines changed

eFormAPI/Plugins/BackendConfiguration.Pn/BackendConfiguration.Pn/Controllers/FilesController.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -136,9 +136,9 @@ public async Task<IActionResult> GetArchiveFiles([FromBody] BackendConfiguration
136136
foreach (var fileId in model.FileIds)
137137
{
138138
var uploadedData = await _backendConfigurationFilesService.GetUploadedDataByFileId(fileId);
139-
var ss = await core.GetFileFromS3Storage($"{uploadedData.Checksum}.pdf");
139+
var ss = await core.GetFileFromS3Storage($"{uploadedData.Checksum}.{uploadedData.Extension}");
140140
var operationDataResult = await _backendConfigurationFilesService.GetById(fileId);
141-
var zipArchiveEntry = archive.CreateEntry($"{operationDataResult.Model.FileName}.pdf",
141+
var zipArchiveEntry = archive.CreateEntry($"{operationDataResult.Model.FileName}.{uploadedData.Extension}",
142142
CompressionLevel.Fastest);
143143
await using var zipStream = zipArchiveEntry.Open();
144144
await ss.ResponseStream.CopyToAsync(zipStream);

0 commit comments

Comments
 (0)