last modified is flaky but. whatever
This commit is contained in:
		
							parent
							
								
									6a9ae7237d
								
							
						
					
					
						commit
						e56feaf1d0
					
				| @ -3,11 +3,13 @@ import { statSync } from "fs"; | ||||
| export function modifiedTime() { | ||||
|   return function (_tree, file) { | ||||
|     const path = file.history[0]; | ||||
|     try { | ||||
|     const result = statSync(path); | ||||
|     file.data.astro.frontmatter.lastModified = result.mtime; | ||||
|     } catch (error) { | ||||
|       return; | ||||
|     }     | ||||
|     // try {
 | ||||
|     //   const result = statSync(path);
 | ||||
|     //   file.data.astro.frontmatter.lastModified = result.mtime;
 | ||||
|     // } catch (error) {
 | ||||
|     //   return;
 | ||||
|     // }
 | ||||
|   } | ||||
| } | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user