File tree Expand file tree Collapse file tree 1 file changed +4
-6
lines changed Expand file tree Collapse file tree 1 file changed +4
-6
lines changed Original file line number Diff line number Diff line change @@ -197,12 +197,14 @@ const FilesPage = ({
197197 , [ files ?. content , files ?. pins , selected ] )
198198
199199 if ( ! files || files . type === 'file' ) return null
200-
200+ // if file not found
201+ if ( files . type === 'not-found' ) {
202+ return < FileNotFound path = { files . path } />
203+ }
201204 // Don't render stale content during navigation
202205 if ( files . path && filesPathInfo . path && files . path !== filesPathInfo . path ) {
203206 return null
204207 }
205-
206208 if ( files . type === 'unknown' ) {
207209 const path = files . path
208210
@@ -214,10 +216,6 @@ const FilesPage = ({
214216 </ div >
215217 )
216218 }
217- if ( files . type === 'not-found' ) {
218- return < FileNotFound path = { files . path } />
219- }
220-
221219 const commonProps = {
222220 updateSorting : doFilesUpdateSorting ,
223221 files : files . content || [ ] ,
You can’t perform that action at this time.
0 commit comments