File tree Expand file tree Collapse file tree 1 file changed +7
-5
lines changed
Expand file tree Collapse file tree 1 file changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -115,13 +115,15 @@ export function watchProject(
115115 if ( options [ kProjectWatchInputs ] ) {
116116 // get inputs (filter by whether the last time we rendered
117117 // this input had the exact same content hash)
118- const inputs = paths . filter ( isInputFile ) . filter ( ( input ) => {
119- return ! rendered . has ( input ) ||
120- rendered . get ( input ) !== md5Hash ( Deno . readTextFileSync ( input ) ) ;
121- } ) ;
118+ const inputs = paths . filter ( isInputFile ) . filter ( existsSync ) . filter (
119+ ( input ) => {
120+ return ! rendered . has ( input ) ||
121+ rendered . get ( input ) !== md5Hash ( Deno . readTextFileSync ( input ) ) ;
122+ } ,
123+ ) ;
122124 if ( inputs . length ) {
123125 // record rendered time
124- for ( const input of inputs ) {
126+ for ( const input of inputs . filter ( existsSync ) ) {
125127 rendered . set ( input , md5Hash ( Deno . readTextFileSync ( input ) ) ) ;
126128 }
127129 // render
You can’t perform that action at this time.
0 commit comments