mirror of
https://github.com/OpenRouterTeam/spawn.git
synced 2026-05-22 03:14:57 +00:00
fix: correct syntax error in e2b/lib/common.sh from SC2155 fix
Fixed broken variable assignment that was incorrectly split during SC2155 refactoring. Properly split local declaration from command substitution assignment. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
parent
16b9b1eda1
commit
0f221fe8b5
1 changed files with 4 additions and 3 deletions
|
|
@ -40,10 +40,11 @@ ensure_e2b_token() {
|
|||
if [[ -n "$E2B_API_KEY" ]]; then
|
||||
log_info "Using E2B API key from environment"; return 0
|
||||
fi
|
||||
local config_dir="$HOME/.config/spawn" config_file="$config_dir/e2b.json"
|
||||
local config_dir="$HOME/.config/spawn"
|
||||
local config_file="$config_dir/e2b.json"
|
||||
if [[ -f "$config_file" ]]; then
|
||||
local saved_key 2>/dev/null)
|
||||
saved_key=$(python3 -c "import json; print(json.load(open('$config_file')).get('api_key',''))"
|
||||
local saved_key
|
||||
saved_key=$(python3 -c "import json; print(json.load(open('$config_file')).get('api_key',''))" 2>/dev/null)
|
||||
if [[ -n "$saved_key" ]]; then
|
||||
export E2B_API_KEY="$saved_key"
|
||||
log_info "Using E2B API key from $config_file"; return 0
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue