Fix key not found issue
This commit is contained in:
parent
67544c37ae
commit
5a25cefbe1
@ -64,6 +64,8 @@ async function configUpdateTo_0924() {
|
|||||||
if (!devchatKey && !openaiKey) {
|
if (!devchatKey && !openaiKey) {
|
||||||
openaiKey = await UiUtilWrapper.secretStorageGet("openai_OPENAI_API_KEY");
|
openaiKey = await UiUtilWrapper.secretStorageGet("openai_OPENAI_API_KEY");
|
||||||
devchatKey = await UiUtilWrapper.secretStorageGet("devchat_OPENAI_API_KEY");
|
devchatKey = await UiUtilWrapper.secretStorageGet("devchat_OPENAI_API_KEY");
|
||||||
|
await UiUtilWrapper.storeSecret("openai_OPENAI_API_KEY", "");
|
||||||
|
await UiUtilWrapper.storeSecret("devchat_OPENAI_API_KEY", "");
|
||||||
}
|
}
|
||||||
if (!devchatKey && !openaiKey) {
|
if (!devchatKey && !openaiKey) {
|
||||||
openaiKey = process.env.OPENAI_API_KEY;
|
openaiKey = process.env.OPENAI_API_KEY;
|
||||||
|
@ -6,6 +6,7 @@ export class ApiKeyManager {
|
|||||||
static toProviderKey(provider: string) : string | undefined {
|
static toProviderKey(provider: string) : string | undefined {
|
||||||
let providerNameMap = {
|
let providerNameMap = {
|
||||||
"openai": "OpenAI",
|
"openai": "OpenAI",
|
||||||
|
"devchat": "DevChat",
|
||||||
"cohere": "Cohere",
|
"cohere": "Cohere",
|
||||||
"anthropic": "Anthropic",
|
"anthropic": "Anthropic",
|
||||||
"replicate": "Replicate",
|
"replicate": "Replicate",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user