conductor-node 7.4.6 → 7.4.8
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/README.md +8 -6
- package/dist/package.json +1 -1
- package/dist/src/Client.js +6 -6
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -120,11 +120,13 @@ The response includes the following:
|
|
|
120
120
|
|
|
121
121
|
```ts
|
|
122
122
|
{
|
|
123
|
-
// Whether we can connect to the end-user's
|
|
124
|
-
isConnected: false
|
|
125
|
-
// If `isConnected=false`,
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
123
|
+
// Whether we can connect to the end-user's QuickBooks Desktop.
|
|
124
|
+
isConnected: false,
|
|
125
|
+
// If `isConnected=false`, an `error` like the following will exist:
|
|
126
|
+
error: {
|
|
127
|
+
code: "QBWC_CONNECTION_ERROR",
|
|
128
|
+
developerMessage: "QBWC Error 0x80040408: Could not start QuickBooks.",
|
|
129
|
+
endUserMessage: "An error occurred while connecting to QuickBooks Desktop. Please ensure QuickBooks Desktop is running and the correct company file is open, then try again.",
|
|
130
|
+
}
|
|
129
131
|
}
|
|
130
132
|
```
|
package/dist/package.json
CHANGED
package/dist/src/Client.js
CHANGED
|
@@ -25,7 +25,7 @@ class Client {
|
|
|
25
25
|
this.graphqlClient = new graphql_request_1.GraphQLClient(`${this.serverURL}/graphql`, {
|
|
26
26
|
headers: {
|
|
27
27
|
Authorization: `Bearer ${apiKey}`,
|
|
28
|
-
"User-Agent": `${package_json_1.default.name}/${package_json_1.default.version} (Node.js ${process.version})`,
|
|
28
|
+
"User-Agent": `${package_json_1.default.name}/${package_json_1.default.version} (Node.js ${process.version}; ${process.platform} ${process.arch})`,
|
|
29
29
|
},
|
|
30
30
|
});
|
|
31
31
|
this.graphqlOperations = (0, operationTypes_1.getSdk)(this.graphqlClient);
|
|
@@ -119,12 +119,12 @@ class Client {
|
|
|
119
119
|
}
|
|
120
120
|
const nestedError = response.errors?.[0];
|
|
121
121
|
if (nestedError?.extensions["code"] === "GRAPHQL_VALIDATION_FAILED") {
|
|
122
|
-
throw new Error(`The Conductor server is no longer compatible with your version of "${package_json_1.default.name}". Please run "yarn
|
|
122
|
+
throw new Error(`The Conductor server is no longer compatible with your version of "${package_json_1.default.name}". Please run "yarn upgrade ${package_json_1.default.name}@latest --latest" to update.`);
|
|
123
123
|
}
|
|
124
124
|
const errorMessage = nestedError?.message ??
|
|
125
|
-
// Though
|
|
126
|
-
// we've seen it occur (e.g., attempting to access
|
|
127
|
-
// environment when `ngrok` is not running locally).
|
|
125
|
+
// Though `ClientError.response.error` is *not* defined in the type
|
|
126
|
+
// definition, we've seen it occur (e.g., attempting to access the
|
|
127
|
+
// `development` environment when `ngrok` is not running locally).
|
|
128
128
|
response["error"];
|
|
129
129
|
if (errorMessage !== undefined) {
|
|
130
130
|
throw new Error(errorMessage);
|
|
@@ -142,7 +142,7 @@ class Client {
|
|
|
142
142
|
.toString()
|
|
143
143
|
.trim();
|
|
144
144
|
if (currentVersion !== latestVersion) {
|
|
145
|
-
console.warn(chalk_1.default.yellow(`⚠️ A new version of Conductor is available! You are using "${package_json_1.default.name}" version ${currentVersion} but the latest version is ${latestVersion}. Please run "yarn
|
|
145
|
+
console.warn(chalk_1.default.yellow(`⚠️ A new version of Conductor is available! You are using "${package_json_1.default.name}" version ${currentVersion} but the latest version is ${latestVersion}. Please run "yarn upgrade ${package_json_1.default.name} --latest" to update.`));
|
|
146
146
|
}
|
|
147
147
|
}
|
|
148
148
|
}
|
package/package.json
CHANGED