From 31af65d4d9f119fd56a9fb80ecc5a160802851c6 Mon Sep 17 00:00:00 2001 From: Ashwin Kumar Date: Sat, 27 Apr 2024 13:26:28 -0700 Subject: [PATCH] cleanup --- .../core/__tests__/parseAWSExports.test.ts | 23 ------------------- packages/core/src/parseAWSExports.ts | 4 +--- 2 files changed, 1 insertion(+), 26 deletions(-) diff --git a/packages/core/__tests__/parseAWSExports.test.ts b/packages/core/__tests__/parseAWSExports.test.ts index 772c4c3e89c..c599ed347d3 100644 --- a/packages/core/__tests__/parseAWSExports.test.ts +++ b/packages/core/__tests__/parseAWSExports.test.ts @@ -197,29 +197,6 @@ describe('parseAWSExports', () => { ).toStrictEqual(expected); }); - it('should parse valid aws-exports.js for Geo', () => { - const expected = { - Geo: { - LocationService: amazonLocationServiceV4, - }, - }; - // aws-exports.js has geo "search_indices" in snake_case - expect( - parseAWSExports({ - aws_project_region: 'us-west-2', - geo: { amazon_location_service: amazonLocationService }, - }), - ).toStrictEqual(expected); - - // aws-exports.js has geo "searchIndices" in camelCase - expect( - parseAWSExports({ - aws_project_region: 'us-west-2', - geo: { amazon_location_service: amazonLocationServiceV4 }, - }), - ).toStrictEqual(expected); - }); - it('should fallback to IAM auth mode if Appsync auth type is invalid', () => { expect( parseAWSExports({ diff --git a/packages/core/src/parseAWSExports.ts b/packages/core/src/parseAWSExports.ts index 535e6ddaa9e..e6b6cc5bba7 100644 --- a/packages/core/src/parseAWSExports.ts +++ b/packages/core/src/parseAWSExports.ts @@ -255,9 +255,7 @@ export const parseAWSExports = ( ...amazon_location_service, maps: amazon_location_service.maps, geofenceCollections: amazon_location_service.geofenceCollections, - searchIndices: - amazon_location_service.search_indices ?? - amazon_location_service.searchIndices, + searchIndices: amazon_location_service.search_indices, region: amazon_location_service.region, }, }