File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -8,7 +8,10 @@ type Bindings = {
88
99const app = new Hono < { Bindings : Bindings } > ( ) ;
1010
11- function getCorsHeaders ( c : { env : Bindings ; req : { header : ( name : string ) => string | undefined } } ) {
11+ function getCorsHeaders ( c : {
12+ env : Bindings ;
13+ req : { header : ( name : string ) => string | undefined } ;
14+ } ) {
1215 const allowed = c . env . ALLOWED_ORIGIN ;
1316 const origin = c . req . header ( 'origin' ) ;
1417 // When ALLOWED_ORIGIN is set, only reflect it if the request origin matches.
@@ -90,7 +93,6 @@ function isValidCacheEntry(data: unknown): data is {
9093 if ( typeof obj . result !== 'object' || obj . result === null ) return false ;
9194 const result = obj . result as Record < string , unknown > ;
9295 return Array . isArray ( result . days ) ;
93-
9496}
9597
9698// --- Cache routes (only active when R2 binding RESULTS is present) ---
You can’t perform that action at this time.
0 commit comments