perf: 修改 更新切换

This commit is contained in:
ibuler
2023-06-15 14:31:31 +08:00
parent d880e5cb8c
commit 59ee3eff17

View File

@@ -35,7 +35,10 @@ async function changeOrg(org, reload = true, vm = null) {
}
// 替换 Path 中的 UUID
const idRegex = /\/?([a-fA-F0-9]{8}-(?:[a-fA-F0-9]{4}-){3}[a-fA-F0-9]{12})|(-?\d+(\.\d+)?)\/?/
path = path.replace(idRegex, '')
const i = path.search(idRegex)
if (i !== -1) {
path = path.slice(0, i + 1)
}
// 替换 Query 中的 UUID
const newQuery = {}