Merge pull request #14341 from Budibase/budi-8550-s3-upload-signed-url-missing-aws-endpoint-when-not

fix AWS datasource when endpoint is unspecified
This commit is contained in:
Andrew Thompson 2024-08-08 14:16:28 +01:00 committed by GitHub
commit 705dfd96b4
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -304,7 +304,7 @@ export const getSignedUploadURL = async function (ctx: Ctx) {
try {
const s3 = new AWS.S3({
region: awsRegion,
endpoint: datasource?.config?.endpoint as string,
endpoint: datasource?.config?.endpoint || undefined,
accessKeyId: datasource?.config?.accessKeyId as string,
secretAccessKey: datasource?.config?.secretAccessKey as string,
apiVersion: "2006-03-01",