@@ -91,21 +91,21 @@ export function initApp(commandLineValues: CommandLineOptions) {
91
91
const COMPUTE_JS_DIR = commandLineValues . output as string ;
92
92
const computeJsDir = path . resolve ( COMPUTE_JS_DIR ) ;
93
93
94
- const PUBLIC_DIR = options [ 'public-dir' ] as string | undefined ;
94
+ const PUBLIC_DIR = options [ 'public-dir' ] ;
95
95
if ( PUBLIC_DIR == null ) {
96
96
console . error ( "❌ required parameter --public-dir not provided." ) ;
97
97
process . exit ( 1 ) ;
98
98
}
99
99
const publicDir = path . resolve ( PUBLIC_DIR ) ;
100
100
101
- const BUILD_STATIC_DIR = options [ 'static-dir' ] as string | undefined ;
101
+ const BUILD_STATIC_DIR = options [ 'static-dir' ] ;
102
102
const buildStaticDir = BUILD_STATIC_DIR != null ? path . resolve ( BUILD_STATIC_DIR ) : null ;
103
103
104
- const spa = options [ 'spa' ] as string | null | undefined ;
105
- const notFoundPage = options [ 'not-found-page' ] as string | null | undefined ;
104
+ const spa = options [ 'spa' ] ;
105
+ const notFoundPage = options [ 'not-found-page' ] ;
106
106
107
- const autoIndex = options [ 'auto-index' ] as string [ ] | null | undefined ;
108
- const autoExt = options [ 'auto-ext' ] as string [ ] | null | undefined ;
107
+ const autoIndex = options [ 'auto-index' ] ;
108
+ const autoExt = options [ 'auto-ext' ] ;
109
109
110
110
let spaFilename = spa ;
111
111
@@ -156,7 +156,7 @@ export function initApp(commandLineValues: CommandLineOptions) {
156
156
const author = options [ 'author' ] ;
157
157
const name = options [ 'name' ] ;
158
158
const description = options [ 'description' ] ;
159
- const fastlyServiceId = options [ 'service-id' ] as string | undefined ;
159
+ const fastlyServiceId = options [ 'service-id' ] ;
160
160
161
161
let spaRel : string | null = spaFilename != null ? path . relative ( path . resolve ( ) , spaFilename ) : null ;
162
162
if ( spaRel != null && ! spaRel . startsWith ( '..' ) ) {
0 commit comments