完善folder页面的web接口实现
This commit is contained in:
@@ -11,6 +11,7 @@ import {
|
||||
} from "react"
|
||||
import { useTranslations } from "next-intl"
|
||||
import { subscribe } from "@/lib/platform"
|
||||
import { randomUUID } from "@/lib/utils"
|
||||
import { inferLiveToolName } from "@/lib/tool-call-normalization"
|
||||
import {
|
||||
acpConnect,
|
||||
@@ -536,7 +537,7 @@ function connectionsReducer(
|
||||
const updated = { ...conn, status: action.status }
|
||||
if (action.status === "prompting") {
|
||||
updated.liveMessage = {
|
||||
id: crypto.randomUUID(),
|
||||
id: randomUUID(),
|
||||
role: "assistant",
|
||||
content: [],
|
||||
startedAt: Date.now(),
|
||||
|
||||
@@ -9,6 +9,7 @@ import {
|
||||
useState,
|
||||
type ReactNode,
|
||||
} from "react"
|
||||
import { randomUUID } from "@/lib/utils"
|
||||
import {
|
||||
ExternalLink,
|
||||
Eye,
|
||||
@@ -147,7 +148,7 @@ async function saveGenericAccount(
|
||||
(a) => a.username === creds.username && extractHost(a.server_url) === host
|
||||
)
|
||||
if (!isDuplicate) {
|
||||
const newId = crypto.randomUUID()
|
||||
const newId = randomUUID()
|
||||
await saveAccountToken(newId, creds.password)
|
||||
await updateGitHubAccounts({
|
||||
accounts: [
|
||||
@@ -283,7 +284,7 @@ export function GitCredentialProvider({ children }: { children: ReactNode }) {
|
||||
)
|
||||
if (!isDuplicate) {
|
||||
const newAccount = {
|
||||
id: crypto.randomUUID(),
|
||||
id: randomUUID(),
|
||||
server_url: serverUrl,
|
||||
username: result.username ?? "unknown",
|
||||
scopes: result.scopes,
|
||||
|
||||
Reference in New Issue
Block a user