Skip to content

Fix local file uploads - #61

Closed
jmazzahacks wants to merge 1 commit into
imagekit-developer:masterfrom
Really-Bad-Apps:master
Closed

Fix local file uploads#61
jmazzahacks wants to merge 1 commit into
imagekit-developer:masterfrom
Really-Bad-Apps:master

Conversation

@jmazzahacks

Copy link
Copy Markdown

Fixed local image uploading.

In the current version, 3.2.0 the following will not work:

image_file_path = 'some path/some image.png'
result = imagekit.upload_file(file=image_file_path, file_name=os.path.basename(image_file_path))

the PR fixes this by opening the file correctly for the MultipartEncoder

Fixed local image uploading once again.
@imagekitio

Copy link
Copy Markdown
Contributor

We support base64 upload as well which is also string. This is by design. If buffer needs to be passed, the consumer of SDK has to open the file and pass that.

@imagekitio imagekitio closed this Feb 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants