@orpc/server 0.35.0 → 0.35.1
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/{chunk-EYGVJA7A.js → chunk-JBPBLCBJ.js} +2 -2
- package/dist/{chunk-OXB4YX67.js → chunk-OWMUECGT.js} +2 -2
- package/dist/{chunk-CVIWJKJC.js → chunk-SUGWQSMQ.js} +2 -2
- package/dist/fetch.js +3 -3
- package/dist/hono.js +3 -3
- package/dist/next.js +3 -3
- package/dist/node.js +2 -2
- package/dist/plugins.js +1 -1
- package/dist/standard.js +2 -2
- package/package.json +3 -3
@@ -2,7 +2,7 @@ import {
|
|
2
2
|
RPCCodec,
|
3
3
|
RPCMatcher,
|
4
4
|
StandardHandler
|
5
|
-
} from "./chunk-
|
5
|
+
} from "./chunk-SUGWQSMQ.js";
|
6
6
|
|
7
7
|
// src/adapters/fetch/utils.ts
|
8
8
|
import { once } from "@orpc/shared";
|
@@ -133,4 +133,4 @@ export {
|
|
133
133
|
standardResponseToFetchResponse,
|
134
134
|
RPCHandler
|
135
135
|
};
|
136
|
-
//# sourceMappingURL=chunk-
|
136
|
+
//# sourceMappingURL=chunk-JBPBLCBJ.js.map
|
@@ -60,7 +60,7 @@ var CORSPlugin = class {
|
|
60
60
|
const origin = Array.isArray(interceptorOptions.request.headers.origin) ? interceptorOptions.request.headers.origin.join(",") : interceptorOptions.request.headers.origin || "";
|
61
61
|
const allowedOrigin = await value(this.options.origin, origin, interceptorOptions);
|
62
62
|
const allowedOriginArr = Array.isArray(allowedOrigin) ? allowedOrigin : [allowedOrigin];
|
63
|
-
if (allowedOriginArr.includes(origin)) {
|
63
|
+
if (allowedOriginArr.includes(origin) || allowedOriginArr.includes("*")) {
|
64
64
|
result.response.headers["access-control-allow-origin"] = origin;
|
65
65
|
}
|
66
66
|
if (!allowedOriginArr.includes("*")) {
|
@@ -108,4 +108,4 @@ export {
|
|
108
108
|
CORSPlugin,
|
109
109
|
ResponseHeadersPlugin
|
110
110
|
};
|
111
|
-
//# sourceMappingURL=chunk-
|
111
|
+
//# sourceMappingURL=chunk-OWMUECGT.js.map
|
@@ -9,7 +9,7 @@ import {
|
|
9
9
|
} from "./chunk-NOA3GBJQ.js";
|
10
10
|
import {
|
11
11
|
CompositePlugin
|
12
|
-
} from "./chunk-
|
12
|
+
} from "./chunk-OWMUECGT.js";
|
13
13
|
|
14
14
|
// src/adapters/standard/handler.ts
|
15
15
|
import { toORPCError } from "@orpc/contract";
|
@@ -305,4 +305,4 @@ export {
|
|
305
305
|
RPCCodec,
|
306
306
|
RPCMatcher
|
307
307
|
};
|
308
|
-
//# sourceMappingURL=chunk-
|
308
|
+
//# sourceMappingURL=chunk-SUGWQSMQ.js.map
|
package/dist/fetch.js
CHANGED
@@ -4,10 +4,10 @@ import {
|
|
4
4
|
fetchRequestToStandardRequest,
|
5
5
|
standardBodyToFetchBody,
|
6
6
|
standardResponseToFetchResponse
|
7
|
-
} from "./chunk-
|
8
|
-
import "./chunk-
|
7
|
+
} from "./chunk-JBPBLCBJ.js";
|
8
|
+
import "./chunk-SUGWQSMQ.js";
|
9
9
|
import "./chunk-NOA3GBJQ.js";
|
10
|
-
import "./chunk-
|
10
|
+
import "./chunk-OWMUECGT.js";
|
11
11
|
export {
|
12
12
|
RPCHandler,
|
13
13
|
fetchReToStandardBody,
|
package/dist/hono.js
CHANGED
@@ -4,10 +4,10 @@ import {
|
|
4
4
|
fetchRequestToStandardRequest,
|
5
5
|
standardBodyToFetchBody,
|
6
6
|
standardResponseToFetchResponse
|
7
|
-
} from "./chunk-
|
8
|
-
import "./chunk-
|
7
|
+
} from "./chunk-JBPBLCBJ.js";
|
8
|
+
import "./chunk-SUGWQSMQ.js";
|
9
9
|
import "./chunk-NOA3GBJQ.js";
|
10
|
-
import "./chunk-
|
10
|
+
import "./chunk-OWMUECGT.js";
|
11
11
|
|
12
12
|
// src/adapters/hono/middleware.ts
|
13
13
|
import { value } from "@orpc/shared";
|
package/dist/next.js
CHANGED
@@ -4,10 +4,10 @@ import {
|
|
4
4
|
fetchRequestToStandardRequest,
|
5
5
|
standardBodyToFetchBody,
|
6
6
|
standardResponseToFetchResponse
|
7
|
-
} from "./chunk-
|
8
|
-
import "./chunk-
|
7
|
+
} from "./chunk-JBPBLCBJ.js";
|
8
|
+
import "./chunk-SUGWQSMQ.js";
|
9
9
|
import "./chunk-NOA3GBJQ.js";
|
10
|
-
import "./chunk-
|
10
|
+
import "./chunk-OWMUECGT.js";
|
11
11
|
|
12
12
|
// src/adapters/next/serve.ts
|
13
13
|
import { value } from "@orpc/shared";
|
package/dist/node.js
CHANGED
@@ -2,9 +2,9 @@ import {
|
|
2
2
|
RPCCodec,
|
3
3
|
RPCMatcher,
|
4
4
|
StandardHandler
|
5
|
-
} from "./chunk-
|
5
|
+
} from "./chunk-SUGWQSMQ.js";
|
6
6
|
import "./chunk-NOA3GBJQ.js";
|
7
|
-
import "./chunk-
|
7
|
+
import "./chunk-OWMUECGT.js";
|
8
8
|
|
9
9
|
// src/adapters/node/utils.ts
|
10
10
|
import { Buffer, File } from "node:buffer";
|
package/dist/plugins.js
CHANGED
package/dist/standard.js
CHANGED
@@ -4,9 +4,9 @@ import {
|
|
4
4
|
RPCSerializer,
|
5
5
|
StandardHandler,
|
6
6
|
serializeRPCJson
|
7
|
-
} from "./chunk-
|
7
|
+
} from "./chunk-SUGWQSMQ.js";
|
8
8
|
import "./chunk-NOA3GBJQ.js";
|
9
|
-
import "./chunk-
|
9
|
+
import "./chunk-OWMUECGT.js";
|
10
10
|
export {
|
11
11
|
RPCCodec,
|
12
12
|
RPCMatcher,
|
package/package.json
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"name": "@orpc/server",
|
3
3
|
"type": "module",
|
4
|
-
"version": "0.35.
|
4
|
+
"version": "0.35.1",
|
5
5
|
"license": "MIT",
|
6
6
|
"homepage": "https://orpc.unnoq.com",
|
7
7
|
"repository": {
|
@@ -64,8 +64,8 @@
|
|
64
64
|
},
|
65
65
|
"dependencies": {
|
66
66
|
"content-disposition": "^0.5.4",
|
67
|
-
"@orpc/contract": "0.35.
|
68
|
-
"@orpc/shared": "0.35.
|
67
|
+
"@orpc/contract": "0.35.1",
|
68
|
+
"@orpc/shared": "0.35.1"
|
69
69
|
},
|
70
70
|
"devDependencies": {
|
71
71
|
"light-my-request": "^6.5.1"
|