mirror of
https://github.com/Aider-AI/aider.git
synced 2025-06-02 18:54:59 +00:00
fix: Default to free tier if OpenRouter tier check fails
This commit is contained in:
parent
b4f9258f3c
commit
3bc4064b61
1 changed files with 2 additions and 2 deletions
|
@ -38,8 +38,8 @@ def check_openrouter_tier(api_key):
|
||||||
# According to the documentation, 'is_free_tier' will be true if the user has never paid
|
# According to the documentation, 'is_free_tier' will be true if the user has never paid
|
||||||
return data.get("data", {}).get("is_free_tier", True) # Default to True if not found
|
return data.get("data", {}).get("is_free_tier", True) # Default to True if not found
|
||||||
except Exception:
|
except Exception:
|
||||||
# If there's any error, we'll default to assuming paid tier to be safe
|
# If there's any error, we'll default to assuming free tier
|
||||||
return False
|
return True
|
||||||
|
|
||||||
|
|
||||||
def try_to_select_default_model():
|
def try_to_select_default_model():
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue