I could not understand @dorilama … how to solve?
Simple function to read a file proprieties…
Bubble accepted this structure in another code…
What do you mean?
I’m at the end of my day and can’t explain it easier than this: bubble requires that the beginning of your code must be exactly the string I posted before, not any other thing, don’t add a name to the function. There is at least another topic about this exact problem in the forum.
Checked a thousand times… (20 lines of code…)
Some libs like “crypto” works like a charm…
While “Image-Size”, “fast-image-size”, “sharp”, " GraphicsMagick", and many other, doesn’t…
This code does not trigger the editor error in a server-side action.
What error do you get?
Are you using this code in a client-side action? Client side actions must be sync and must start with function(properties, context) {
Server Side
My intention is to use get data from “uploaded files”, in the BackEnd.
No error… it halts execution, nothing in the WF is executed after this simple plugin call;
I’ve tried many libs, same thing…
What is interesting, If I change this “same call” to return a hash, let’s say (sha256), with “cryto lib”, it works…
If I use a lib to get “Image Dimensions”, Bubble halts WF… (no matter the lib I use).
So, It is buffering, but cannot execute the lib function.
this is completely different from what you posted (the editor complaining about syntax error)
If you are using a library that was last published 7 years ago to run in a different environment I’m afraid there is nothing to do here.
for image-size there is documentation with enough examples, you should try them. If you want to try something different then you should try the code locally first, to have a better debigging experience, and then test it on bubble.