datastake-daf 0.6.496 → 0.6.498
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/services/index.js
CHANGED
|
@@ -6150,9 +6150,12 @@ class BaseHTTPService {
|
|
|
6150
6150
|
this._axiosInitialized = false;
|
|
6151
6151
|
}
|
|
6152
6152
|
_ensureAxiosInitialized() {
|
|
6153
|
+
console.log('[BaseHTTPService] Checking axios initialization:', this._axiosInitialized);
|
|
6153
6154
|
if (!this._axiosInitialized) {
|
|
6155
|
+
console.log('[BaseHTTPService] Setting up axios...');
|
|
6154
6156
|
this.setupAxios();
|
|
6155
6157
|
this._axiosInitialized = true;
|
|
6158
|
+
console.log('[BaseHTTPService] Axios setup complete!');
|
|
6156
6159
|
}
|
|
6157
6160
|
}
|
|
6158
6161
|
setupAxios() {
|
|
@@ -6419,6 +6422,10 @@ function createLazyService(ServiceClass) {
|
|
|
6419
6422
|
let instance = null;
|
|
6420
6423
|
return new Proxy({}, {
|
|
6421
6424
|
get(target, prop) {
|
|
6425
|
+
// Handle special properties
|
|
6426
|
+
if (prop === 'constructor') return ServiceClass;
|
|
6427
|
+
if (prop === Symbol.toStringTag) return ServiceClass.name;
|
|
6428
|
+
|
|
6422
6429
|
// Create instance on first property access
|
|
6423
6430
|
if (!instance) {
|
|
6424
6431
|
instance = new ServiceClass();
|
|
@@ -6426,7 +6433,12 @@ function createLazyService(ServiceClass) {
|
|
|
6426
6433
|
const value = instance[prop];
|
|
6427
6434
|
|
|
6428
6435
|
// Bind methods to maintain correct 'this' context
|
|
6429
|
-
|
|
6436
|
+
if (typeof value === 'function') {
|
|
6437
|
+
return function (...args) {
|
|
6438
|
+
return value.apply(instance, args);
|
|
6439
|
+
};
|
|
6440
|
+
}
|
|
6441
|
+
return value;
|
|
6430
6442
|
}
|
|
6431
6443
|
});
|
|
6432
6444
|
}
|
package/package.json
CHANGED
|
@@ -54,9 +54,12 @@ export class BaseHTTPService {
|
|
|
54
54
|
}
|
|
55
55
|
|
|
56
56
|
_ensureAxiosInitialized() {
|
|
57
|
+
console.log('[BaseHTTPService] Checking axios initialization:', this._axiosInitialized);
|
|
57
58
|
if (!this._axiosInitialized) {
|
|
59
|
+
console.log('[BaseHTTPService] Setting up axios...');
|
|
58
60
|
this.setupAxios();
|
|
59
61
|
this._axiosInitialized = true;
|
|
62
|
+
console.log('[BaseHTTPService] Axios setup complete!');
|
|
60
63
|
}
|
|
61
64
|
}
|
|
62
65
|
|
|
@@ -17,6 +17,10 @@ export function createLazyService(ServiceClass) {
|
|
|
17
17
|
|
|
18
18
|
return new Proxy({}, {
|
|
19
19
|
get(target, prop) {
|
|
20
|
+
// Handle special properties
|
|
21
|
+
if (prop === 'constructor') return ServiceClass;
|
|
22
|
+
if (prop === Symbol.toStringTag) return ServiceClass.name;
|
|
23
|
+
|
|
20
24
|
// Create instance on first property access
|
|
21
25
|
if (!instance) {
|
|
22
26
|
instance = new ServiceClass();
|
|
@@ -25,7 +29,13 @@ export function createLazyService(ServiceClass) {
|
|
|
25
29
|
const value = instance[prop];
|
|
26
30
|
|
|
27
31
|
// Bind methods to maintain correct 'this' context
|
|
28
|
-
|
|
32
|
+
if (typeof value === 'function') {
|
|
33
|
+
return function(...args) {
|
|
34
|
+
return value.apply(instance, args);
|
|
35
|
+
};
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
return value;
|
|
29
39
|
}
|
|
30
40
|
});
|
|
31
41
|
}
|