s3 upload issue

default discord avatar
bhavikak
last month
16

hello i'm facing issue when i update alt or title of image. i got an error that is in a image

  • default discord avatar
    tylandavis
    last month

    what does your Media/Uploads config look like?

  • default discord avatar
    bhavikak
    last month


    heyy @tylandavis this is my config.

  • default discord avatar
    cbregante
    last month

    could you show your dependencies please

  • default discord avatar
    tylandavis
    last month

    yeah I imagine there might be something in the formatImageName function causing this issue.



    also, I would suggest taking a look at the official cloud storage plugin:

    https://github.com/payloadcms/plugin-cloud-storage
  • default discord avatar
    bhavikak
    last month

    no @tylandavis if i remove formaImageName it's showing me this error.







    hello i'm waitong for response.

  • default discord avatar
    tylandavis
    2 weeks ago

    @bhavikak I'm not familiar with the pattern you are using here for you s3 uploads. Can you confirm that the uploads are working when you first create?



    I wonder if the issue may be that the creating and updating need different patterns.



    I would suggest abstracting your S3 functions outside of your config, and calling them using Payload Hooks.

  • default discord avatar
    EzeRangel
    2 weeks ago

    Hi, this happens when you try to create images' variants but the original image is smaller (in dimensions), so Payload doesn't create a variant and the plugin tryes to save it but it is undefined.



    Try to update your

    payload-s3-upload

    plugin.

  • default discord avatar
    bhavikak
    2 weeks ago

    thanks @tylandavis and @EzeRangel i'll try your suggestions.



    heyy @EzeRangel i just update a version and it's working fine.

  • default discord avatar
    EzeRangel
    2 weeks ago

    đź‘Ť great!

Open the post
Continue the discussion in Discord
Like what we're doing?
Star us on GitHub!

Star

Connect with the Payload Community on Discord

Discord

online

Can't find what you're looking for?

Get help straight from the Payload team with an Enterprise License.