remove AMAZON_AWS_HOST export, fix regex per review feedback

Signed-off-by: Leon Stein <leons727@gmail.com>
This commit is contained in:
Leon Stein
2021-12-28 11:42:23 -05:00
parent 60dee60d9b
commit e662ee528b
2 changed files with 6 additions and 10 deletions
+3 -3
View File
@@ -16,7 +16,7 @@
import { Config } from '@backstage/config';
export const AMAZON_AWS_HOST = 'amazonaws.com';
const AMAZON_AWS_HOST = 'amazonaws.com';
/**
* The configuration parameters for a single AWS S3 provider.
@@ -83,12 +83,12 @@ export function readAwsS3IntegrationConfig(
pathname = url.pathname;
} catch {
throw new Error(
`Invalid awsS3 integration config, endpoint '${endpoint}' is not a valid URL`,
`invalid awsS3 integration config, endpoint '${endpoint}' is not a valid URL`,
);
}
if (pathname !== '/') {
throw new Error(
`Invalid awsS3 integration config, endpoints cannot contain path, got '${endpoint}'`,
`invalid awsS3 integration config, endpoints cannot contain path, got '${endpoint}'`,
);
}
} else {