Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🐛 Bug Report: storage.createFile() looses mimeType and stops at 0 bytes when uploading #61

Closed
2 tasks done
trashcoder opened this issue Jul 3, 2023 · 1 comment
Closed
2 tasks done
Labels
bug Something isn't working

Comments

@trashcoder
Copy link

👟 Reproduction steps

When using sdk-for-web for react-native createFile looses the mimetype and stops at 0 bytes when uploading a file

const blob = new Blob(['Hello World'], {
type: 'plain/text',
} as BlobOptions);
//@ts-ignore
const file = new File([blob], fileName, {type: blob.type});
const response = await storage.createFile(BUCKET_ID, ID.unique(), file);

Bildschirmfoto 2023-07-03 um 23 23 00

The same behaviour is when i upload an image from rn-image-picker.

👍 Expected behavior

it should upload a file and keeping the mimetype.

👎 Actual Behavior

it stops at 0 bytes and looses the mimeType.

🎲 Appwrite version

Different version (specify in environment)

💻 Operating system

Linux

🧱 Your Environment

Appwrite Client Version: 11.0.0
Appwrite Server: 1.3.7
React-Native Version: 0.71.11

👀 Have you spent some time to check if this issue has been raised before?

  • I checked and didn't find similar issue

🏢 Have you read the Code of Conduct?

@trashcoder trashcoder added the bug Something isn't working label Jul 3, 2023
@stnguyen90
Copy link
Contributor

@trashcoder, thanks for creating this issue! 🙏🏼 Unfortunately, createFile doesn't work with react-native. See #27

@stnguyen90 stnguyen90 closed this as not planned Won't fix, can't repro, duplicate, stale Sep 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants