fix: fix cannot submit aws claude config (close #1343)

This commit is contained in:
JustSong 2024-04-21 11:04:34 +08:00
parent 2369025842
commit 35ba1da984

View File

@ -156,13 +156,9 @@ const EditChannel = () => {
}, []); }, []);
const submit = async () => { const submit = async () => {
// some provider as AWS need both AK and SK rather than a single key, if (inputs.key === "") {
// so we need to combine them into a single key to achieve the best compatibility. inputs.key = `${config.ak}|${config.sk}|${config.region}`;
if (inputs.ak && inputs.sk) {
console.log(`combine ak ${inputs.ak} and sk ${inputs.sk}`, inputs.ak, inputs.sk);
inputs.key = `${inputs.ak}\n${inputs.sk}`;
} }
if (!isEdit && (inputs.name === '' || inputs.key === '')) { if (!isEdit && (inputs.name === '' || inputs.key === '')) {
showInfo('请填写渠道名称和渠道密钥!'); showInfo('请填写渠道名称和渠道密钥!');
return; return;