roboto-js 1.0.3 → 1.0.4

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/rbt_api.js CHANGED
@@ -73,7 +73,6 @@ var RbtApi = exports["default"] = /*#__PURE__*/function () {
73
73
  value: function () {
74
74
  var _create = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(type) {
75
75
  var dataHash,
76
- params,
77
76
  response,
78
77
  record,
79
78
  _args2 = arguments;
@@ -82,11 +81,9 @@ var RbtApi = exports["default"] = /*#__PURE__*/function () {
82
81
  case 0:
83
82
  dataHash = _args2.length > 1 && _args2[1] !== undefined ? _args2[1] : {};
84
83
  _context2.prev = 1;
85
- params = {
86
- type: type
87
- };
84
+ debugger;
88
85
  _context2.next = 5;
89
- return this.axios.post('/object_service/createObject', [params.type]);
86
+ return this.axios.post('/object_service/createObject', [type, dataHash]);
90
87
  case 5:
91
88
  response = _context2.sent;
92
89
  record = response.data;
package/package.json CHANGED
@@ -1,11 +1,12 @@
1
1
  {
2
2
  "name": "roboto-js",
3
- "version": "1.0.3",
3
+ "version": "1.0.4",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "scripts": {
7
7
  "build": "babel src --out-dir dist",
8
- "test": "echo \"Error: no test specified\" && exit 1"
8
+ "test": "echo \"Error: no test specified\" && exit 1",
9
+ "prepublishOnly": "npm run build"
9
10
  },
10
11
  "author": "",
11
12
  "license": "ISC",
package/src/rbt_api.js CHANGED
@@ -49,10 +49,8 @@ export default class RbtApi {
49
49
 
50
50
  async create(type, dataHash={}) {
51
51
  try {
52
- const params = {
53
- type
54
- };
55
- const response = await this.axios.post('/object_service/createObject', [params.type]);
52
+ debugger;
53
+ const response = await this.axios.post('/object_service/createObject', [type, dataHash]);
56
54
  const record = response.data;
57
55
 
58
56
  if(dataHash){