@terros-inc/sdk 1.0.6 → 1.0.7
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.mjs +4 -6
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -1,7 +1,4 @@
|
|
|
1
|
-
import { fileURLToPath } from "node:url";
|
|
2
|
-
import { dirname, join } from "node:path";
|
|
3
1
|
import { platform, release } from "node:os";
|
|
4
|
-
import { readFileSync } from "node:fs";
|
|
5
2
|
//#region src/clients/account.ts
|
|
6
3
|
var AccountStatusClient = class {
|
|
7
4
|
api;
|
|
@@ -152,17 +149,18 @@ function isResponseError(response) {
|
|
|
152
149
|
return typeof response === "object" && response !== null && response.type === "error" && Boolean(response.error);
|
|
153
150
|
}
|
|
154
151
|
//#endregion
|
|
152
|
+
//#region package.json
|
|
153
|
+
var version = "1.0.7";
|
|
154
|
+
//#endregion
|
|
155
155
|
//#region src/analytics.ts
|
|
156
156
|
function getAnalyticsHeaders() {
|
|
157
157
|
if (typeof globalThis.process === "undefined") return {};
|
|
158
158
|
try {
|
|
159
|
-
const __dirname = dirname(fileURLToPath(import.meta.url));
|
|
160
|
-
const packageJson = JSON.parse(readFileSync(join(__dirname, "../package.json"), "utf8"));
|
|
161
159
|
return {
|
|
162
160
|
"Terros-Platform": platform(),
|
|
163
161
|
"Terros-Platform-Version": release(),
|
|
164
162
|
"Terros-Bundle-Identifier": "com.terros.sdk",
|
|
165
|
-
"Terros-App-Version":
|
|
163
|
+
"Terros-App-Version": version
|
|
166
164
|
};
|
|
167
165
|
} catch {
|
|
168
166
|
return {};
|