@pgxsinkit/server 0.1.36 → 0.1.41

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pgxsinkit/server",
3
- "version": "0.1.36",
3
+ "version": "0.1.41",
4
4
  "keywords": [
5
5
  "tanstack-intent"
6
6
  ],
@@ -31,7 +31,7 @@
31
31
  "build": "bun --cwd ../.. run build:public-packages"
32
32
  },
33
33
  "dependencies": {
34
- "@pgxsinkit/contracts": "0.1.36"
34
+ "@pgxsinkit/contracts": "0.1.41"
35
35
  },
36
36
  "peerDependencies": {
37
37
  "drizzle-orm": "1.0.0-rc.4"
@@ -11,7 +11,7 @@ description: >-
11
11
  metadata:
12
12
  type: task
13
13
  library: "@pgxsinkit/server"
14
- library_version: "0.1.32"
14
+ library_version: "0.1.41"
15
15
  source: https://pgxsinkit.github.io/start/deploying-the-server/
16
16
  ---
17
17
 
@@ -121,9 +121,12 @@ async function forwardShapeRequest(
121
121
  method: "GET",
122
122
  signal: request.signal,
123
123
  }).catch((error: unknown) => {
124
- if (isAbortError(error)) {
125
- // Client disconnected — no meaningful response can be sent.
126
- // Return a 499 (client closed request) to avoid a 500 in logs.
124
+ // Client disconnected — no meaningful response can be sent.
125
+ // Return a 499 (client closed request) to avoid a 500 in logs.
126
+ // Keyed on the signal's aborted state first: Bun can reject an aborted fetch with a
127
+ // literal `null` (no AbortError to pattern-match), and once the caller aborted there is
128
+ // nobody to answer regardless of what the rejection value looks like.
129
+ if (request.signal.aborted || isAbortError(error)) {
127
130
  return new Response(null, { status: 499, statusText: "Client Closed Request" });
128
131
  }
129
132
  throw error;