fix: resolve embedded api key lookup
This commit is contained in:
parent
b30bae89ed
commit
b6ac2d860d
@ -374,11 +374,11 @@ export async function compactEmbeddedPiSession(params: {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
const apiKey = await getApiKeyForModel({
|
const apiKeyInfo = await getApiKeyForModel({
|
||||||
model,
|
model,
|
||||||
cfg: params.config,
|
cfg: params.config,
|
||||||
});
|
});
|
||||||
authStorage.setRuntimeApiKey(model.provider, apiKey.apiKey);
|
authStorage.setRuntimeApiKey(model.provider, apiKeyInfo.apiKey);
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
return {
|
return {
|
||||||
ok: false,
|
ok: false,
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user