-
Notifications
You must be signed in to change notification settings - Fork 27
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
img.getMIME is not a function #5
Comments
One more thing. As I can see you're using: I think it's not right because jimp uses error-first callback here and the first argument will contain an error and the second will contain the result (buffer in our case). Please, take a look at this - https://github.com/oliver-moran/jimp#writing-to-buffers. In comments there are
It should be I am still investigating the issue with
But this function does not work with the result of your |
Thanks for reporting the issue!
Yes, indeed this is wrong usage. I made this for a long time ago and I could not find until you report it 😂. I'm going to fix the document now. Again, thanks for reporting this. Let's get back to the original issue here, I assume this is probably upstream issue: I could find such method on the upstream source code: https://github.com/oliver-moran/jimp/blob/f7b5e5b543b012069c513ae8a2368c388e54e6ad/index.js#L834-L837 However, I'm not quite sure when this method is applied in which version. But I could find that the @turakvlad Could you provide which version of |
@preco21, no problem. I am happy to help. I am using Please, try it on your side. If everything is okay, it looks like we resolve this issue 😃 |
You were right. Releasing |
@turakvlad Hmm, I think this is going to be much more tricky: #3 I have downgraded it because of the issue causing some sort of errors on browser. Actually this should not be an issue since this module is focused on node environment. But, as you know, better than having nothing.
The thing is that they have different build to support browser: I believe this issue was on the use of browser build of the module in the node-like environment like Electron via webpack. Since webpack automatically manages the environment as like node, so the developers don't have a reason to use browser build and webpack will do rest of jobs. So hacky and simple the workaround is to change According to So I installed the module via I can confirm that is not the same one. Since this is an Thoughts? |
Hi, @preco21! I am sorry for my delayed response. I have downgraded my To my mind, Maybe, it would be better not to upgrade |
@turakvlad Alright, thanks for pointing out that. I’ll check it. |
Probably need to update the readme on NPM also.. |
I'm also noticing a third reduction in file size between All source images I used are jpg and the result is 367.8 KB to 212.2 KB. |
@elipeters If I understand what you meant correctly: Using If so, I guess this is yet another I have plan to make it more like a general purpose in v3, still working on it. |
So now that getMIME is removed from merge-img, now what? |
@PokeTehDoge Now things left is to make some stuff better. But I have been so busy for a couple of months so I couldn’t get to make some stuff for this module. I’ll start work on it as soon as I finish my job. But, always PRs are welcome. |
I have tried to use your sample but it does not work for me with
Node 8.9.4
(of course, I have provided the paths to the real images on my local machine). I am gettingimg.getMIME is not a function
.Thanks for the help.
The text was updated successfully, but these errors were encountered: