@slavmak2486/bx24ts 1.1.26 → 1.1.28
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/BX24Server.ts +10 -2
- package/dist/BX24Server.js +10 -2
- package/package.json +1 -1
package/BX24Server.ts
CHANGED
|
@@ -40,7 +40,11 @@ export class BX24Server extends baseBX24{
|
|
|
40
40
|
if (debug){
|
|
41
41
|
this.callMethod('event.offline.list', {auth_connector:authConnector}, ress=>{
|
|
42
42
|
if (ress.error()){
|
|
43
|
-
|
|
43
|
+
const result=new CallResult({error_description:String(ress.error())}, {
|
|
44
|
+
data:[debug?{auth_connector:authConnector}:{clear:clear?1:0, auth_connector:authConnector}],
|
|
45
|
+
method:debug?'event.offline.list':'event.offline.get'
|
|
46
|
+
},this, 500);
|
|
47
|
+
resolve(result);
|
|
44
48
|
}
|
|
45
49
|
if (!ress.answer) ress.answer={};
|
|
46
50
|
if (!ress.answer.result) ress.answer.result={};
|
|
@@ -51,7 +55,11 @@ export class BX24Server extends baseBX24{
|
|
|
51
55
|
else{
|
|
52
56
|
this.callMethod('event.offline.get', {clear:clear?1:0, auth_connector:authConnector}, ress=>{
|
|
53
57
|
if (ress.error()){
|
|
54
|
-
|
|
58
|
+
const result=new CallResult({error_description:String(ress.error())}, {
|
|
59
|
+
data:[debug?{auth_connector:authConnector}:{clear:clear?1:0, auth_connector:authConnector}],
|
|
60
|
+
method:debug?'event.offline.list':'event.offline.get'
|
|
61
|
+
},this, 500);
|
|
62
|
+
resolve(result);
|
|
55
63
|
}
|
|
56
64
|
if (!ress.answer) ress.answer={};
|
|
57
65
|
if (!ress.answer.result) ress.answer.result={};
|
package/dist/BX24Server.js
CHANGED
|
@@ -32,7 +32,11 @@ class BX24Server extends BX24_1.baseBX24 {
|
|
|
32
32
|
this.callMethod('event.offline.list', { auth_connector: authConnector }, ress => {
|
|
33
33
|
var _a;
|
|
34
34
|
if (ress.error()) {
|
|
35
|
-
|
|
35
|
+
const result = new callResult_1.CallResult({ error_description: String(ress.error()) }, {
|
|
36
|
+
data: [debug ? { auth_connector: authConnector } : { clear: clear ? 1 : 0, auth_connector: authConnector }],
|
|
37
|
+
method: debug ? 'event.offline.list' : 'event.offline.get'
|
|
38
|
+
}, this, 500);
|
|
39
|
+
resolve(result);
|
|
36
40
|
}
|
|
37
41
|
if (!ress.answer)
|
|
38
42
|
ress.answer = {};
|
|
@@ -46,7 +50,11 @@ class BX24Server extends BX24_1.baseBX24 {
|
|
|
46
50
|
this.callMethod('event.offline.get', { clear: clear ? 1 : 0, auth_connector: authConnector }, ress => {
|
|
47
51
|
var _a, _b;
|
|
48
52
|
if (ress.error()) {
|
|
49
|
-
|
|
53
|
+
const result = new callResult_1.CallResult({ error_description: String(ress.error()) }, {
|
|
54
|
+
data: [debug ? { auth_connector: authConnector } : { clear: clear ? 1 : 0, auth_connector: authConnector }],
|
|
55
|
+
method: debug ? 'event.offline.list' : 'event.offline.get'
|
|
56
|
+
}, this, 500);
|
|
57
|
+
resolve(result);
|
|
50
58
|
}
|
|
51
59
|
if (!ress.answer)
|
|
52
60
|
ress.answer = {};
|