@dargmuesli/nuxt-vio 3.0.0-beta.7 → 3.0.0-beta.8

Sign up to get free protection for your applications and to get access to all the features.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dargmuesli/nuxt-vio",
3
- "version": "3.0.0-beta.7",
3
+ "version": "3.0.0-beta.8",
4
4
  "type": "module",
5
5
  "publishConfig": {
6
6
  "access": "public"
@@ -6,11 +6,7 @@ import { TIMEZONE_HEADER_KEY } from '../../utils/constants'
6
6
  import { getTimezone } from '../../utils/networking'
7
7
 
8
8
  export default defineEventHandler(async (event) => {
9
- setRequestHeader(
10
- event,
11
- TIMEZONE_HEADER_KEY,
12
- (await getTimezone(event)) || 'UTC',
13
- )
9
+ setRequestHeader(event, TIMEZONE_HEADER_KEY, await getTimezone(event))
14
10
  // setContentSecurityPolicy(event);
15
11
  setResponseHeaders(event)
16
12
  })
@@ -25,7 +21,7 @@ export default defineEventHandler(async (event) => {
25
21
  // );
26
22
  // };
27
23
 
28
- const setRequestHeader = (event: H3Event, name: string, value: string) => {
24
+ const setRequestHeader = (event: H3Event, name: string, value?: string) => {
29
25
  event.node.req.headers[name] = value
30
26
  }
31
27