jeanbmar / payload-s3-upload

Send Payload CMS uploads to Amazon S3
MIT License
56 stars 9 forks source link

Error on creating images variants #16

Closed EzeRangel closed 1 year ago

EzeRangel commented 1 year ago

Hi it seems I found a bug, while trying to upload images with resized variants I receive this error:

{ "errors": [ { "message": "The \"path\" argument must be of type string. Received null" } ] }

This is my imageSizes config:

imageSizes: [
    {
      name: "small",
      width: 400,
      height: 400,
      position: "center"
    },
    {
      name: "medium",
      width: 800,
      height: undefined,
      position: "center"
    },
  ],

Reproduction: Just try to upload an image which dimensions are lower than one of the variants, for ex: an 700x300 jpg.