Skip to content
Snippets Groups Projects
Unverified Commit 33b1a11d authored by GyDi's avatar GyDi
Browse files

fix: parse logger time

parent 06dabf1e
No related branches found
No related tags found
No related merge requests found
import dayjs from "dayjs";
import { invoke } from "@tauri-apps/api/tauri";
import { Notice } from "@/components/base";
......@@ -10,7 +11,8 @@ export async function getClashLogs() {
.map((log) => {
const result = log.match(regex);
if (result) {
const [_, time, type, payload] = result;
const [_, _time, type, payload] = result;
const time = dayjs(_time).format("MM-DD HH:mm:ss");
return { time, type, payload };
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment