@openfn/language-maximo 0.3.4 → 0.4.1

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/dist/index.cjs CHANGED
@@ -104,8 +104,8 @@ function fetch(params) {
104
104
  maxauth: encoded
105
105
  }
106
106
  },
107
- function(error, response, getResponseBody) {
108
- error = assembleError({ error, response });
107
+ function(err, response, getResponseBody) {
108
+ const error = assembleError({ error: err, response });
109
109
  if (error) {
110
110
  console.error("GET failed.");
111
111
  console.log(response);
@@ -118,8 +118,8 @@ function fetch(params) {
118
118
  url: postUrl,
119
119
  json: JSON.parse(getResponseBody)
120
120
  },
121
- function(error2, response2, postResponseBody) {
122
- error2 = assembleError({ error: error2, response: response2 });
121
+ function(err2, response2, postResponseBody) {
122
+ const error2 = assembleError({ error: err2, response: response2 });
123
123
  if (error2) {
124
124
  console.error("POST failed.");
125
125
  reject(error2);
@@ -169,8 +169,8 @@ function create(params) {
169
169
  maxauth: encoded
170
170
  }
171
171
  },
172
- function(error, response, body2) {
173
- error = assembleError({ error, response });
172
+ function(err, response, body2) {
173
+ const error = assembleError({ error: err, response });
174
174
  if (error) {
175
175
  reject(error);
176
176
  console.log(body2);
@@ -218,8 +218,8 @@ function update(params) {
218
218
  patchtype: "MERGE"
219
219
  }
220
220
  },
221
- function(error, response, body2) {
222
- error = assembleError({ error, response });
221
+ function(err, response, body2) {
222
+ const error = assembleError({ error: err, response });
223
223
  if (error) {
224
224
  reject(error);
225
225
  console.log(body2);
@@ -266,8 +266,8 @@ function update75(params) {
266
266
  patchtype: "MERGE"
267
267
  }
268
268
  },
269
- function(error, response, body2) {
270
- error = assembleError({ error, response });
269
+ function(err, response, body2) {
270
+ const error = assembleError({ error: err, response });
271
271
  if (error) {
272
272
  reject(error);
273
273
  console.log(body2);
package/dist/index.js CHANGED
@@ -78,8 +78,8 @@ function fetch(params) {
78
78
  maxauth: encoded
79
79
  }
80
80
  },
81
- function(error, response, getResponseBody) {
82
- error = assembleError({ error, response });
81
+ function(err, response, getResponseBody) {
82
+ const error = assembleError({ error: err, response });
83
83
  if (error) {
84
84
  console.error("GET failed.");
85
85
  console.log(response);
@@ -92,8 +92,8 @@ function fetch(params) {
92
92
  url: postUrl,
93
93
  json: JSON.parse(getResponseBody)
94
94
  },
95
- function(error2, response2, postResponseBody) {
96
- error2 = assembleError({ error: error2, response: response2 });
95
+ function(err2, response2, postResponseBody) {
96
+ const error2 = assembleError({ error: err2, response: response2 });
97
97
  if (error2) {
98
98
  console.error("POST failed.");
99
99
  reject(error2);
@@ -143,8 +143,8 @@ function create(params) {
143
143
  maxauth: encoded
144
144
  }
145
145
  },
146
- function(error, response, body2) {
147
- error = assembleError({ error, response });
146
+ function(err, response, body2) {
147
+ const error = assembleError({ error: err, response });
148
148
  if (error) {
149
149
  reject(error);
150
150
  console.log(body2);
@@ -192,8 +192,8 @@ function update(params) {
192
192
  patchtype: "MERGE"
193
193
  }
194
194
  },
195
- function(error, response, body2) {
196
- error = assembleError({ error, response });
195
+ function(err, response, body2) {
196
+ const error = assembleError({ error: err, response });
197
197
  if (error) {
198
198
  reject(error);
199
199
  console.log(body2);
@@ -240,8 +240,8 @@ function update75(params) {
240
240
  patchtype: "MERGE"
241
241
  }
242
242
  },
243
- function(error, response, body2) {
244
- error = assembleError({ error, response });
243
+ function(err, response, body2) {
244
+ const error = assembleError({ error: err, response });
245
245
  if (error) {
246
246
  reject(error);
247
247
  console.log(body2);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openfn/language-maximo",
3
- "version": "0.3.4",
3
+ "version": "0.4.1",
4
4
  "description": "An IBM Maximo EAM Language Pack for OpenFn",
5
5
  "main": "dist/index.cjs",
6
6
  "author": "Open Function Group",
@@ -12,7 +12,7 @@
12
12
  "configuration-schema.json"
13
13
  ],
14
14
  "dependencies": {
15
- "@openfn/language-common": "^1.7.5",
15
+ "@openfn/language-common": "^1.8.1",
16
16
  "base-64": "^0.1.0",
17
17
  "request": "^2.88.2",
18
18
  "utf8": "^2.1.2"
@@ -50,6 +50,7 @@
50
50
  "test": "mocha --experimental-specifier-resolution=node --no-warnings",
51
51
  "test:watch": "mocha -w --experimental-specifier-resolution=node --no-warnings",
52
52
  "clean": "rimraf dist types docs",
53
- "pack": "pnpm pack --pack-destination ../../dist"
53
+ "pack": "pnpm pack --pack-destination ../../dist",
54
+ "lint": "eslint src"
54
55
  }
55
56
  }
@@ -6,7 +6,7 @@
6
6
  * create('foo'),
7
7
  * delete('bar')
8
8
  * )(state)
9
- * @function
9
+ * @private
10
10
  * @param {Operations} operations - Operations to be performed.
11
11
  * @returns {Operation}
12
12
  */