Skip to content

Commit

Permalink
Removed Mimetypes nuget
Browse files Browse the repository at this point in the history
  • Loading branch information
vitalii-bezuhlyi committed Mar 6, 2024
1 parent c1f0067 commit f7801bb
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
6 changes: 2 additions & 4 deletions Apps.Memoq/Actions/FileActions.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
using System.Net.Mime;
using System.Xml.Linq;
using Apps.MemoQ;
using Apps.Memoq.Contracts;
using Apps.Memoq.Models;
using Apps.Memoq.Models.Dto;
Expand All @@ -15,7 +14,6 @@
using Apps.Memoq.Utils.FileUploader;
using Apps.Memoq.Utils.FileUploader.Managers;
using Apps.Memoq.Utils.Xliff;
using Blackbird.Applications.Sdk.Common.Files;
using MQS.TasksService;
using Blackbird.Applications.Sdk.Common.Invocation;
using Blackbird.Applications.SDK.Extensions.FileManagement.Interfaces;
Expand Down Expand Up @@ -207,11 +205,11 @@ public async Task<UploadFileResponse> UploadAndImportFileToProjectAsXliff(
throw new("Unsupported XLIFF version");
}
}

fileBytes ??= await file.GetByteData();

var fileName = string.IsNullOrEmpty(request.FileName) ? request.File.Name : request.FileName;
var contentType = MimeTypes.GetMimeType(fileName);
var contentType = MediaTypeNames.Application.Octet;
var fileReference = await _fileManagementClient.UploadAsync(new MemoryStream(fileBytes),
contentType, fileName);
return await UploadAndImportFileToProject(new UploadDocumentToProjectRequest
Expand Down
4 changes: 0 additions & 4 deletions Apps.Memoq/Apps.MemoQ.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,6 @@
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="MimeTypes" Version="2.4.1">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="NSwag.ApiDescription.Client" Version="13.20.0">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
Expand Down

0 comments on commit f7801bb

Please sign in to comment.