Storage adapter context


I am wondering if there is a way to identify from where the image uploader is called? For instance, when I upload an image for a post content vs for a user profile picture or blog cover.

Is there or will it be a way to contextualize the media uploader?

Thank you,

Hey @eexit :wave: I’m having a bit of trouble understanding the request, what is your use case for identifying where the image uploader is called from?

Hi @Kevin,

Thanks for your answer. I use a customized Cloudinary storage adapter and I apply retina transformation on-the-fly, which is really handy. However, there are some uploads I would like to change my transformation settings or disable it (blog cover, profile pic, etc.).

If, from the storage adapter I could get a context key, I could filter down this context and apply specific transformations accordingly. I know it sounds very specific but the ability to know which context is calling the storage adapter could be very useful for better flexibility like picking a specific storage depending which context it is and so on.

Let me know if I wasn’t clear.

Thank you!

Thanks, that’s a useful use-case to know about! :smile: There’s currently no context available about the image type, images are completely abstracted so that the single “image” type can be used anywhere in the system.

It would be helpful to add your use-case to the Automatic thumbnailing/resizing of image uploads Ideas topic so that it can be taken on board when planning the next advancement in image handling.

1 Like