修复导出配置问题

This commit is contained in:
Alcedo 2023-08-29 09:20:17 +08:00
parent b6c0a04285
commit 4457fab038

View file

@ -1280,7 +1280,7 @@ Poe 模式会调用 Poe 中的 Claude-instant 进行对话。需要提供 Cookie
if (await redis.exists('CHATGPT:USE') != 0) { if (await redis.exists('CHATGPT:USE') != 0) {
redisConfig.useMode = await redis.get('CHATGPT:USE') redisConfig.useMode = await redis.get('CHATGPT:USE')
} }
const filepath = path.join('plugins/chatgpt-plugin/resources', 'view.json') const filepath = path.join('plugins/chatgpt-plugin/resources/view', 'setting_view.json')
const configView = JSON.parse(fs.readFileSync(filepath, 'utf8')) const configView = JSON.parse(fs.readFileSync(filepath, 'utf8'))
const configJson = JSON.stringify({ const configJson = JSON.stringify({
chatConfig: Config, chatConfig: Config,
@ -1289,7 +1289,7 @@ Poe 模式会调用 Poe 中的 Claude-instant 进行对话。需要提供 Cookie
}) })
console.log(configJson) console.log(configJson)
const buf = Buffer.from(configJson) const buf = Buffer.from(configJson)
e.friend.sendFile(buf, `ChatGPT-Plugin Config ${new Date()}.json`) e.friend.sendFile(buf, `ChatGPT-Plugin Config ${Date.now()}.json`)
return true return true
} }