@8ms/helpers 1.1.70 → 1.1.75

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.
@@ -16,9 +16,6 @@ const invoke = async ({ crawler }) => {
16
16
  // Fire the event but don't wait for it to complete
17
17
  const apiResponse = await global.awsGlueClient.send(command);
18
18
  // Success
19
- if ((0, isResponse200_1.default)({ apiResponse })) {
20
- return true;
21
- }
22
- return false;
19
+ return (0, isResponse200_1.default)({ apiResponse });
23
20
  };
24
21
  exports.default = invoke;
@@ -1,7 +1,8 @@
1
+ declare type GetCustomer = {
2
+ customerId: string;
3
+ };
1
4
  /**
2
5
  * Return the Google Ads Client with the specified customer set.
3
6
  */
4
- declare const getCustomer: ({ customerId }: {
5
- customerId: string;
6
- }) => Promise<any>;
7
+ declare const getCustomer: ({ customerId }: GetCustomer) => Promise<any>;
7
8
  export default getCustomer;
@@ -4,7 +4,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
4
4
  * Return the Google Ads Client with the specified customer set.
5
5
  */
6
6
  const getCustomer = async ({ customerId }) => {
7
- // Login as a customer
8
7
  const customer = global.googleAdsClient.instance.Customer({
9
8
  customer_id: customerId,
10
9
  login_customer_id: global.googleAdsClient.mccAccountId,
@@ -13,12 +13,11 @@ const initClient = async ({ parameter }) => {
13
13
  if (!global.googleAdsClient.instance) {
14
14
  const { GoogleAdsApi } = require('google-ads-api');
15
15
  // Create a new client instance
16
- global.googleAdsClient.instance =
17
- new GoogleAdsApi({
18
- client_id: parameter.clientId,
19
- client_secret: parameter.clientSecret,
20
- developer_token: parameter.developerToken,
21
- });
16
+ global.googleAdsClient.instance = new GoogleAdsApi({
17
+ client_id: parameter.clientId,
18
+ client_secret: parameter.clientSecret,
19
+ developer_token: parameter.developerToken,
20
+ });
22
21
  global.googleAdsClient.mccAccountId = parameter.mccAccountId;
23
22
  global.googleAdsClient.refreshToken = parameter.refreshToken;
24
23
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@8ms/helpers",
3
3
  "license": "UNLICENSED",
4
- "version": "1.1.70",
4
+ "version": "1.1.75",
5
5
  "repository": {
6
6
  "type": "git",
7
7
  "url": "git+https://github.com/8millionstories-organisation/8ms-helpers-ts.git"
@@ -16,25 +16,25 @@
16
16
  "axios": "0.27.2",
17
17
  "crypto-js": "4.1.1",
18
18
  "date-fns": "2.29.2",
19
- "date-fns-tz": "1.3.6",
19
+ "date-fns-tz": "1.3.7",
20
20
  "lodash": "4.17.21"
21
21
  },
22
22
  "devDependencies": {
23
- "@aws-sdk/client-s3": "3.161.0",
24
- "@aws-sdk/client-ses": "3.161.0",
25
- "@aws-sdk/client-ssm": "3.161.0",
26
- "@aws-sdk/s3-request-presigner": "3.161.0",
23
+ "@aws-sdk/client-s3": "3.163.0",
24
+ "@aws-sdk/client-ses": "3.163.0",
25
+ "@aws-sdk/client-ssm": "3.163.0",
26
+ "@aws-sdk/s3-request-presigner": "3.163.0",
27
27
  "@babel/preset-env": "7.18.10",
28
28
  "@babel/preset-flow": "7.18.6",
29
29
  "@babel/preset-typescript": "7.18.6",
30
30
  "@google-cloud/bigquery": "6.0.2",
31
- "@google-cloud/storage": "6.4.1",
32
- "@prisma/client": "4.3.0",
31
+ "@google-cloud/storage": "6.4.2",
32
+ "@prisma/client": "4.3.1",
33
33
  "@types/jest": "29.0.0",
34
34
  "@types/lodash": "4.14.184",
35
35
  "@types/node": "18.7.14",
36
- "babel-jest": "29.0.1",
37
- "jest": "29.0.1",
36
+ "babel-jest": "29.0.2",
37
+ "jest": "29.0.2",
38
38
  "node-fetch": "3.2.10",
39
39
  "numbro": "2.3.6",
40
40
  "prisma-query-log": "3.2.0",