@alleyboss/micropay-solana-x402-paywall 3.3.6 → 3.3.7

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.
@@ -245,6 +245,7 @@ function createX402Middleware(config) {
245
245
  return async (req, ctx) => {
246
246
  const compatibleReq = new Proxy(req, {
247
247
  get(target, prop) {
248
+ console.error(`[ProxyDebug] Access req.${String(prop)}`);
248
249
  if (prop === "url") {
249
250
  return target.nextUrl?.pathname || target.url;
250
251
  }
@@ -252,6 +253,7 @@ function createX402Middleware(config) {
252
253
  const headers = target.headers;
253
254
  return new Proxy(headers, {
254
255
  get(hTarget, hProp) {
256
+ console.error(`[ProxyDebug] Access req.headers.${String(hProp)}`);
255
257
  if (typeof hProp === "string" && !["get", "set", "has", "delete", "entries", "keys", "values", "forEach", "append"].includes(hProp) && typeof hTarget[hProp] === "undefined") {
256
258
  return hTarget.get(hProp) || void 0;
257
259
  }
@@ -244,6 +244,7 @@ function createX402Middleware(config) {
244
244
  return async (req, ctx) => {
245
245
  const compatibleReq = new Proxy(req, {
246
246
  get(target, prop) {
247
+ console.error(`[ProxyDebug] Access req.${String(prop)}`);
247
248
  if (prop === "url") {
248
249
  return target.nextUrl?.pathname || target.url;
249
250
  }
@@ -251,6 +252,7 @@ function createX402Middleware(config) {
251
252
  const headers = target.headers;
252
253
  return new Proxy(headers, {
253
254
  get(hTarget, hProp) {
255
+ console.error(`[ProxyDebug] Access req.headers.${String(hProp)}`);
254
256
  if (typeof hProp === "string" && !["get", "set", "has", "delete", "entries", "keys", "values", "forEach", "append"].includes(hProp) && typeof hTarget[hProp] === "undefined") {
255
257
  return hTarget.get(hProp) || void 0;
256
258
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alleyboss/micropay-solana-x402-paywall",
3
- "version": "3.3.6",
3
+ "version": "3.3.7",
4
4
  "description": "Production-ready Solana micropayments library wrapper for official x402 SDK",
5
5
  "author": "AlleyBoss",
6
6
  "license": "MIT",