Skip to content

Commit b9a6489

Browse files
committed
Fix response headers
1 parent 0c32c69 commit b9a6489

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

src/components/Response/Response.ts

+1-4
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,8 @@ export const res_500 = (input?: any, options = null) => res(input ? parseInput(i
1919
export const res = (input: any, options = {} as any) => {
2020
const data = parseInput(input);
2121
return new Response(JSON.stringify({ ...data }, undefined, apiker.debug ? 4 : undefined), {
22+
headers: apiker.responseHeaders,
2223
...(Number.isInteger(options) ? { status: options } : options),
23-
headers: {
24-
...apiker.responseHeaders,
25-
...(options.headers || {})
26-
},
2724
});
2825
};
2926

0 commit comments

Comments
 (0)