
Hello, if I upload an image using the .NET SDK, the mimetype for my png images is set to "application/octet-stream" instead of "image/png".
This is my code
```public async Task<string> CreateFileAsync(string bucketId, string filename, string content, string mimeType)
{
using var stream = new MemoryStream(Encoding.UTF8.GetBytes(content));
var inputFile = InputFile.FromStream(stream, filename.ToLower(), mimeType);
var fileId = ID.Unique();
inputFile.Path=filename.ToLower();
try
{
var fileToWrite = await _storage.CreateFile(bucketId, fileId, inputFile, new List<string>());
return fileToWrite.Id;
}
catch (Exception ex)
{
Console.WriteLine($"Error: {ex.Message}");
}
return "";
}```
I added "inputFile.Path=filename.ToLower();" just in case but no difference. What could be the problem?
selfhosted Appwrite Version: 1.4.13 Appwrite Nuget: 0.7.1
Recommended threads
- 404 error when navigating to the team fr...
the version i m running is `1.7.4` as far as i can tell everything is working fine except for this weird bug in the video. when monitoring the appwrite and app...
- [Node.js SDK] Bypass 2GB file limit?
Hello. Using either InputFile.fromPath or InputFile.fromBuffer throws this error: File size (2295467305) is greater than 2 GiB Bucket limit etc. is setup corre...
- Relationship null, even when relationshi...
Hi Everyone, im experiencing issues with set relation data. When im setting the document id from the related database most of them seem fine, except one table. ...
