33import path from 'node:path'
44import url from 'node:url'
55
6- import Jwt from '@hapi/jwt'
6+ import Jwt from '@hapi/jwt'
77import Hapi from '@hapi/hapi'
88// import Cookie from '@hapi/cookie'
99import Inert from '@hapi/inert'
@@ -38,7 +38,7 @@ async function setup() {
3838 parser : ( query ) => qs . parse ( query ) ,
3939 } ,
4040 routes : {
41- " cors" : true ,
41+ cors : true ,
4242 files : {
4343 relativeTo : path . join (
4444 path . dirname ( url . fileURLToPath ( import . meta. url ) ) ,
@@ -73,7 +73,7 @@ async function setup() {
7373 nbf : true ,
7474 exp : true ,
7575 maxAgeSec : 14400 , // 4 hours
76- timeSkewSec : 15
76+ timeSkewSec : 15 ,
7777 } ,
7878 httpAuthScheme : 'Bearer' ,
7979 headerName : 'authorization' ,
@@ -82,10 +82,10 @@ async function setup() {
8282 isValid : true ,
8383 credentials : artifacts . decoded . payload . nt ,
8484 }
85- }
85+ } ,
8686 } )
8787
88- server . auth . default ( 'nt_jwt_strategy' ) ;
88+ server . auth . default ( 'nt_jwt_strategy' )
8989
9090 server . route ( {
9191 method : 'GET' ,
@@ -113,7 +113,9 @@ async function setup() {
113113
114114 server . events . on ( 'request' , ( request , event , tags ) => {
115115 if ( tags . error ) {
116- console . error ( `Request ${ event . request } error: ${ event . error ? event . error . message : 'unknown' } ` ) ;
116+ console . error (
117+ `Request ${ event . request } error: ${ event . error ? event . error . message : 'unknown' } ` ,
118+ )
117119 }
118120 } )
119121
0 commit comments