@8ms/helpers 1.1.76 → 1.1.77

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/initClients.d.ts CHANGED
@@ -19,14 +19,14 @@ declare type InitClients = {
19
19
  parameterName: string;
20
20
  };
21
21
  googleBigQuery?: {
22
- projectIds: string | string[];
22
+ projectId: string;
23
23
  };
24
24
  googleConfig?: {
25
25
  parameterName: string;
26
26
  };
27
27
  googleSheets?: boolean;
28
28
  googleStorage?: {
29
- projectIds: string | string[];
29
+ projectId: string;
30
30
  };
31
31
  prisma?: {
32
32
  debug?: boolean;
package/initClients.js CHANGED
@@ -3,7 +3,6 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- const getArray_1 = __importDefault(require("./array/getArray"));
7
6
  const initClient_1 = __importDefault(require("./aws/athenaExpress/initClient"));
8
7
  const initClient_2 = __importDefault(require("./aws/glue/initClient"));
9
8
  const initClient_3 = __importDefault(require("./aws/s3/initClient"));
@@ -62,14 +61,11 @@ const initClients = async ({ athenaExpress, awsConfig, awsGlue, awsS3, awsSes, a
62
61
  name: googleConfig.parameterName,
63
62
  });
64
63
  // BigQuery
65
- if (googleBigQuery && googleBigQuery.projectIds) {
66
- const googleBigQueryProjectIds = (0, getArray_1.default)({ input: googleBigQuery.projectIds });
67
- for (let i = 0; i < googleBigQueryProjectIds.length; i++) {
68
- (0, initClient_7.default)({
69
- parameter: googleParameter,
70
- projectId: googleBigQueryProjectIds[i],
71
- });
72
- }
64
+ if (googleBigQuery && googleBigQuery.projectId) {
65
+ (0, initClient_7.default)({
66
+ parameter: googleParameter,
67
+ projectId: googleBigQuery.projectId,
68
+ });
73
69
  }
74
70
  // Google Sheets
75
71
  if (googleSheets) {
@@ -78,14 +74,11 @@ const initClients = async ({ athenaExpress, awsConfig, awsGlue, awsS3, awsSes, a
78
74
  });
79
75
  }
80
76
  // Google Storage
81
- if (googleStorage && googleStorage.projectIds) {
82
- const googleStorageProjectIds = (0, getArray_1.default)({ input: googleStorage.projectIds });
83
- for (let i = 0; i < googleStorageProjectIds.length; i++) {
84
- (0, initClient_9.default)({
85
- parameter: googleParameter,
86
- projectId: googleStorageProjectIds[i],
87
- });
88
- }
77
+ if (googleStorage && googleStorage.projectId) {
78
+ (0, initClient_9.default)({
79
+ parameter: googleParameter,
80
+ projectId: googleBigQuery.projectId,
81
+ });
89
82
  }
90
83
  }
91
84
  // Google Ads authentication using SSM Parameter
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@8ms/helpers",
3
3
  "license": "UNLICENSED",
4
- "version": "1.1.76",
4
+ "version": "1.1.77",
5
5
  "repository": {
6
6
  "type": "git",
7
7
  "url": "git+https://github.com/8millionstories-organisation/8ms-helpers-ts.git"