@agnostack/next-shopify 1.14.1-beta.11 → 1.14.1-beta.13

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/CHANGELOG.md CHANGED
@@ -1,3 +1,17 @@
1
+ ## [1.14.1-beta.13](https://github.com/agnostack/next-shopify/compare/v1.14.1-beta.12...v1.14.1-beta.13) (2023-12-06)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * wip ([65cb793](https://github.com/agnostack/next-shopify/commit/65cb793b99613677cf52aed2b5f3f754fc17559e))
7
+
8
+ ## [1.14.1-beta.12](https://github.com/agnostack/next-shopify/compare/v1.14.1-beta.11...v1.14.1-beta.12) (2023-12-06)
9
+
10
+
11
+ ### Bug Fixes
12
+
13
+ * wip ([6f9f83a](https://github.com/agnostack/next-shopify/commit/6f9f83a55755b546b2f98318f10d84d36c4a92a3))
14
+
1
15
  ## [1.14.1-beta.11](https://github.com/agnostack/next-shopify/compare/v1.14.1-beta.10...v1.14.1-beta.11) (2023-12-06)
2
16
 
3
17
 
@@ -1,2 +1,2 @@
1
1
  export function ensureRawBody(req: any): Promise<any>;
2
- //# sourceMappingURL=request.d.ts.map
2
+ //# sourceMappingURL=body.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"body.d.ts","sourceRoot":"","sources":["../../../src/lib/utils/body.js"],"names":[],"mappings":"AAEO,sDAoBN"}
@@ -4,7 +4,14 @@ exports.ensureRawBody = void 0;
4
4
  const tslib_1 = require("tslib");
5
5
  const raw_body_1 = tslib_1.__importDefault(require("raw-body"));
6
6
  const ensureRawBody = (req) => tslib_1.__awaiter(void 0, void 0, void 0, function* () {
7
- return ((0, raw_body_1.default)(req)
7
+ if (req.text) {
8
+ console.log(`>>> > ensureRawBody > req.text:`, { text1: yield req.text() });
9
+ console.log(`>>> > ensureRawBody > req.text2:`, { text2: yield req.text() });
10
+ }
11
+ else {
12
+ console.log(`>>> > ensureRawBody > req.text3:`, { textFunc: req.text });
13
+ }
14
+ return (0, raw_body_1.default)(req)
8
15
  .then((_rawBody) => _rawBody.toString())
9
16
  .catch((error) => {
10
17
  // NOTE: this is intended to ensure if getRawBody is called 2x w/in a route that it returns the already streamed body
@@ -14,7 +21,7 @@ const ensureRawBody = (req) => tslib_1.__awaiter(void 0, void 0, void 0, functio
14
21
  }
15
22
  console.error(`Error getting raw body for '${req === null || req === void 0 ? void 0 : req.url}'`, error);
16
23
  throw error;
17
- }));
24
+ });
18
25
  });
19
26
  exports.ensureRawBody = ensureRawBody;
20
- //# sourceMappingURL=request.js.map
27
+ //# sourceMappingURL=body.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"body.js","sourceRoot":"","sources":["../../../src/lib/utils/body.js"],"names":[],"mappings":";;;;AAAA,gEAAiC;AAE1B,MAAM,aAAa,GAAG,CAAO,GAAG,EAAE,EAAE;IACzC,IAAI,GAAG,CAAC,IAAI,EAAE;QACZ,OAAO,CAAC,GAAG,CAAC,iCAAiC,EAAE,EAAE,KAAK,EAAE,MAAM,GAAG,CAAC,IAAI,EAAE,EAAE,CAAC,CAAA;QAC3E,OAAO,CAAC,GAAG,CAAC,kCAAkC,EAAE,EAAE,KAAK,EAAE,MAAM,GAAG,CAAC,IAAI,EAAE,EAAE,CAAC,CAAA;KAC7E;SAAM;QACL,OAAO,CAAC,GAAG,CAAC,kCAAkC,EAAE,EAAE,QAAQ,EAAE,GAAG,CAAC,IAAI,EAAE,CAAC,CAAA;KACxE;IAED,OAAO,IAAA,kBAAU,EAAC,GAAG,CAAC;SACnB,IAAI,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,QAAQ,CAAC,QAAQ,EAAE,CAAC;SACvC,KAAK,CAAC,CAAC,KAAK,EAAE,EAAE;QACf,qHAAqH;QACrH,IAAI,CAAC,CAAA,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,IAAI,MAAK,qBAAqB,CAAC,EAAE;YAC3C,OAAO,CAAC,KAAK,CAAC,4BAA4B,EAAE,EAAE,KAAK,EAAE,IAAI,EAAE,GAAG,aAAH,GAAG,uBAAH,GAAG,CAAE,IAAI,EAAE,CAAC,CAAA;YACvE,OAAO,GAAG,aAAH,GAAG,uBAAH,GAAG,CAAE,IAAI,CAAA;SACjB;QAED,OAAO,CAAC,KAAK,CAAC,+BAA+B,GAAG,aAAH,GAAG,uBAAH,GAAG,CAAE,GAAG,GAAG,EAAE,KAAK,CAAC,CAAA;QAChE,MAAM,KAAK,CAAA;IACb,CAAC,CAAC,CAAA;AACN,CAAC,CAAA,CAAA;AApBY,QAAA,aAAa,iBAoBzB"}
@@ -1,8 +1,8 @@
1
1
  export * from "./billing";
2
+ export * from "./body";
2
3
  export * from "./crypto";
3
4
  export * from "./firebase";
4
5
  export * from "./headers";
5
- export * from "./request";
6
6
  export * from "./session";
7
7
  export * from "./shopify";
8
8
  export * from "./shopify-api-js/oauth";
@@ -2,10 +2,10 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
4
  tslib_1.__exportStar(require("./billing"), exports);
5
+ tslib_1.__exportStar(require("./body"), exports);
5
6
  tslib_1.__exportStar(require("./crypto"), exports);
6
7
  tslib_1.__exportStar(require("./firebase"), exports);
7
8
  tslib_1.__exportStar(require("./headers"), exports);
8
- tslib_1.__exportStar(require("./request"), exports);
9
9
  tslib_1.__exportStar(require("./session"), exports);
10
10
  tslib_1.__exportStar(require("./shopify"), exports);
11
11
  tslib_1.__exportStar(require("./shopify-api-js/oauth"), exports);
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/lib/utils/index.js"],"names":[],"mappings":";;;AAAA,oDAAyB;AACzB,mDAAwB;AACxB,qDAA0B;AAC1B,oDAAyB;AACzB,oDAAyB;AACzB,oDAAyB;AACzB,oDAAyB;AACzB,iEAAsC;AACtC,kDAAuB;AACvB,yDAA8B"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/lib/utils/index.js"],"names":[],"mappings":";;;AAAA,oDAAyB;AACzB,iDAAsB;AACtB,mDAAwB;AACxB,qDAA0B;AAC1B,oDAAyB;AACzB,oDAAyB;AACzB,oDAAyB;AACzB,iEAAsC;AACtC,kDAAuB;AACvB,yDAA8B"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agnostack/next-shopify",
3
- "version": "1.14.1-beta.11",
3
+ "version": "1.14.1-beta.13",
4
4
  "author": "agnoStack Dev <developers@agnostack.com> (https://agnostack.com)",
5
5
  "owner": "agnoStack",
6
6
  "description": "Please contact agnoStack via info@agnostack.com for any questions",
@@ -1 +0,0 @@
1
- {"version":3,"file":"request.d.ts","sourceRoot":"","sources":["../../../src/lib/utils/request.js"],"names":[],"mappings":"AAEO,sDAaN"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"request.js","sourceRoot":"","sources":["../../../src/lib/utils/request.js"],"names":[],"mappings":";;;;AAAA,gEAAiC;AAE1B,MAAM,aAAa,GAAG,CAAO,GAAG,EAAE,EAAE;IAAC,OAAA,CAC1C,IAAA,kBAAU,EAAC,GAAG,CAAC;SACZ,IAAI,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,QAAQ,CAAC,QAAQ,EAAE,CAAC;SACvC,KAAK,CAAC,CAAC,KAAK,EAAE,EAAE;QACf,qHAAqH;QACrH,IAAI,CAAC,CAAA,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,IAAI,MAAK,qBAAqB,CAAC,EAAE;YAC3C,OAAO,CAAC,KAAK,CAAC,4BAA4B,EAAE,EAAE,KAAK,EAAE,IAAI,EAAE,GAAG,aAAH,GAAG,uBAAH,GAAG,CAAE,IAAI,EAAE,CAAC,CAAA;YACvE,OAAO,GAAG,aAAH,GAAG,uBAAH,GAAG,CAAE,IAAI,CAAA;SACjB;QAED,OAAO,CAAC,KAAK,CAAC,+BAA+B,GAAG,aAAH,GAAG,uBAAH,GAAG,CAAE,GAAG,GAAG,EAAE,KAAK,CAAC,CAAA;QAChE,MAAM,KAAK,CAAA;IACb,CAAC,CAAC,CACL,CAAA;EAAA,CAAA;AAbY,QAAA,aAAa,iBAazB"}