Error when resizing image TypeError: Cannot set property 'resizedImage' of undefined
See original GitHub issueHello, I installed the Resize Image Extension but it breaks with the following error:
Error when resizing image TypeError: Cannot set property 'resizedImage' of undefined
Screenshot:
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:16 (6 by maintainers)
Top Results From Across the Web
Use HTML5 to resize an image before upload - Stack Overflow
I've thought about moving the file input out of the form and having a hidden input in the form that I set the...
Read more >Cannot set property 'src' of Null in JavaScript | bobbyhadz
The "Cannot set property 'src' of null" error occurs for 2 reasons: Setting the src property on a null value (image element that...
Read more >ReportExecution2005 HTMLFragment problem - Microsoft Q&A
Instead the html fragment is triggering javascript error: Uncaught TypeError: Cannot read properties of undefined (reading 'minWidth') ...
Read more >react-image-file-resizer - npm
React module that can rescaled local images. You can change image's width, height, format, rotation and quality. It returns resized image's ...
Read more >How To Process Images in Node.js With Sharp - DigitalOcean
This tutorial covers using the Node.js library sharp to read an im… ... Second, you'll chain the format() method to the resized image...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I’m struggling to reproduce this. I’ve tried an existing instance and a totally fresh one but I can’t trigger this error.
Could I ask how you are uploading an image? (e.g. web console vs Web SDK vs Android SDK etc).
If I were to stake a guess, when the image is added, we pass it’s data into the resizer function, which attempts to assign a
metadata.resizedImage
field on-top of the original images metadata. I think that depending on how the image is uploaded , that image may not be created with an original metadata field, therefore this error occurs as it’s trying to assign a property to something which doesn’t exist.A simple fix would be to change this line to
metadata: objectMetadata.metadata || {},
.I’d be interested to see though why no metadata is being created by default, to understand where that happens.
Hello, I’m Facing Same Issue Error when resizing image TypeError: Cannot set property ‘resizedImage’ of undefined & Error when deleting temporary files { Error: ENOENT: no such file or directory, unlink
storage-resize-images extension version 0.1.3 configuration parameters -Deployment location us-central1 -Sizes of resized images 200x200,500x500,1240x1240 -Deletion of original file false -other’s are default unset
I have upload it from sdk firebase": “6.3.0”, “firesql”: “2.0.2”, “linq2fire”: “1.0.22”, “react”: “16.8.3”, “react-native”: “0.59.9”, I try installing extension from both way console and cli none of them work for me
And also its not creating resized file name with attached original file name + height,weight its showing direct _200X200