@itutoring/itutoring_application_js_api 1.4.19 → 1.4.20

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.
Files changed (2) hide show
  1. package/apiController.js +14 -2
  2. package/package.json +1 -1
package/apiController.js CHANGED
@@ -104,7 +104,13 @@ class APIController
104
104
  console.log("Error: " + json.error_message);
105
105
  console.log("ErrorCode: " + json.error_code);
106
106
  console.log("StackTrace: " + json.stack_trace);
107
- resolve("Invalid data");
107
+ resolve(JSON.stringify({
108
+ error: {
109
+ message: json.error_message,
110
+ code: json.error_code,
111
+ stackTrace: json.stack_trace
112
+ }
113
+ }));
108
114
  }
109
115
  }
110
116
  }
@@ -168,7 +174,13 @@ class APIController
168
174
  console.log("Error: " + json.error_message);
169
175
  console.log("ErrorCode: " + json.error_code);
170
176
  console.log("StackTrace: " + json.stack_trace);
171
- resolve("Invalid data");
177
+ resolve(JSON.stringify({
178
+ error: {
179
+ message: json.error_message,
180
+ code: json.error_code,
181
+ stackTrace: json.stack_trace
182
+ }
183
+ }));
172
184
  }
173
185
  }
174
186
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@itutoring/itutoring_application_js_api",
3
- "version": "1.4.19",
3
+ "version": "1.4.20",
4
4
  "description": "Javascript API for iTutoring Application",
5
5
  "main": "index.js",
6
6
  "types": "index.d.ts",