mirror of
				https://github.com/zadam/trilium.git
				synced 2025-10-31 18:36:30 +01:00 
			
		
		
		
	fix formatting of date/time
This commit is contained in:
		| @@ -52,11 +52,7 @@ function base64ToUint8Array(base64encoded) { | |||||||
| function getDateFromTS(timestamp) { | function getDateFromTS(timestamp) { | ||||||
|     // Date accepts number of milliseconds since epoch so UTC timestamp works without any extra handling |     // Date accepts number of milliseconds since epoch so UTC timestamp works without any extra handling | ||||||
|     // see https://stackoverflow.com/questions/4631928/convert-utc-epoch-to-local-date-with-javascript |     // see https://stackoverflow.com/questions/4631928/convert-utc-epoch-to-local-date-with-javascript | ||||||
|     const utcDate = new Date(timestamp * 1000); |     return new Date(timestamp * 1000); | ||||||
|  |  | ||||||
|     const localDate = new Date(utcDate.getTime() - utcDate.getTimezoneOffset() * 60 * 1000); |  | ||||||
|  |  | ||||||
|     return localDate; |  | ||||||
| } | } | ||||||
|  |  | ||||||
| function formatTime(date) { | function formatTime(date) { | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user