CatPtain commited on
Commit
f074dfd
·
verified ·
1 Parent(s): bbd2fdd

Upload 65 files

Browse files
Files changed (1) hide show
  1. app/config/config.py +3 -2
app/config/config.py CHANGED
@@ -57,8 +57,9 @@ class Settings(BaseSettings):
57
  @field_validator("ALLOWED_TOKENS", mode="before")
58
  @classmethod
59
  def parse_allowed_tokens(cls, v: Any) -> List[str]:
60
- if isinstance(v, str):
61
- return [token.strip() for token in v.split(",") if token.strip()]
 
62
  return v
63
  BASE_URL: str = f"https://generativelanguage.googleapis.com/{API_VERSION}"
64
  AUTH_TOKEN: str = ""
 
57
  @field_validator("ALLOWED_TOKENS", mode="before")
58
  @classmethod
59
  def parse_allowed_tokens(cls, v: Any) -> List[str]:
60
+ if not isinstance(v, str):
61
+ v = str(v)
62
+ return [token.strip() for token in v.split(",") if token.strip()]
63
  return v
64
  BASE_URL: str = f"https://generativelanguage.googleapis.com/{API_VERSION}"
65
  AUTH_TOKEN: str = ""