wao 0.36.4 → 0.37.0

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.
@@ -25,9 +25,6 @@ function _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o =
25
25
  function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
26
26
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
27
27
  function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
28
- //import { httpbis, createVerifier } from "http-message-signatures"
29
- //import { createPublicKey } from "node:crypto"
30
- //const { verifyMessage } = httpbis
31
28
  var Adaptor = /*#__PURE__*/function () {
32
29
  function Adaptor(_ref) {
33
30
  var hb_url = _ref.hb_url,
@@ -1260,54 +1257,57 @@ var Adaptor = /*#__PURE__*/function () {
1260
1257
  type = null;
1261
1258
  item = null;
1262
1259
  if (valid || true) item = new _arbundles.DataItem(body);
1260
+ _context31.next = 17;
1261
+ return item.setSignature(item.rawSignature);
1262
+ case 17:
1263
1263
  _tags = (0, _utils.tags)(item.tags);
1264
1264
  err = null;
1265
1265
  if (!(_tags.Type === "Process")) {
1266
- _context31.next = 24;
1266
+ _context31.next = 26;
1267
1267
  break;
1268
1268
  }
1269
- _context31.next = 20;
1269
+ _context31.next = 22;
1270
1270
  return this.spawn({
1271
1271
  item: item,
1272
1272
  module: _tags.Module,
1273
1273
  scheduler: _tags.Scheduler
1274
1274
  });
1275
- case 20:
1275
+ case 22:
1276
1276
  res = _context31.sent;
1277
1277
  if (!res) err = "bad requrest";
1278
- _context31.next = 30;
1278
+ _context31.next = 32;
1279
1279
  break;
1280
- case 24:
1280
+ case 26:
1281
1281
  if (!(_tags.Type === "Message")) {
1282
- _context31.next = 29;
1282
+ _context31.next = 31;
1283
1283
  break;
1284
1284
  }
1285
- _context31.next = 27;
1285
+ _context31.next = 29;
1286
1286
  return this.message({
1287
1287
  item: item,
1288
1288
  process: item.target
1289
1289
  });
1290
- case 27:
1291
- _context31.next = 30;
1292
- break;
1293
1290
  case 29:
1291
+ _context31.next = 32;
1292
+ break;
1293
+ case 31:
1294
1294
  err = true;
1295
- case 30:
1295
+ case 32:
1296
1296
  if (!err) {
1297
- _context31.next = 34;
1297
+ _context31.next = 36;
1298
1298
  break;
1299
1299
  }
1300
1300
  return _context31.abrupt("return", {
1301
1301
  status: 400,
1302
1302
  error: err
1303
1303
  });
1304
- case 34:
1304
+ case 36:
1305
1305
  return _context31.abrupt("return", {
1306
1306
  json: {
1307
1307
  id: item.id
1308
1308
  }
1309
1309
  });
1310
- case 35:
1310
+ case 37:
1311
1311
  case "end":
1312
1312
  return _context31.stop();
1313
1313
  }
package/cjs/ao.js CHANGED
@@ -459,8 +459,8 @@ var AO = /*#__PURE__*/function () {
459
459
  Variant: ((_this$variant = this.variant) !== null && _this$variant !== void 0 ? _this$variant : this.module_type === "mainnet") ? "ao.TN.1" : "ao.TN.1",
460
460
  Type: "Module",
461
461
  "Module-Format": "wasm64-unknown-emscripten-draft_2024_02_15",
462
- "Input-Encoding": "JSON-V1",
463
- "Output-Encoding": "JSON-V1",
462
+ "Input-Encoding": "JSON-1",
463
+ "Output-Encoding": "JSON-1",
464
464
  "Memory-Limit": "1-gb",
465
465
  "Compute-Limit": "9000000000000",
466
466
  Extension: "WeaveDrive"