Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
A
aisbf
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexlab
aisbf
Commits
efecd1ff
Commit
efecd1ff
authored
May 16, 2026
by
Stefy Lanza (nextime / spora )
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Again coderai fix
parent
d08f685e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
7 deletions
+12
-7
providers.py
aisbf/routes/dashboard/providers.py
+12
-7
No files found.
aisbf/routes/dashboard/providers.py
View file @
efecd1ff
...
@@ -1020,16 +1020,21 @@ async def dashboard_providers_get_models(request: Request):
...
@@ -1020,16 +1020,21 @@ async def dashboard_providers_get_models(request: Request):
# Get user ID from session
# Get user ID from session
current_user_id
=
request
.
session
.
get
(
'user_id'
)
current_user_id
=
request
.
session
.
get
(
'user_id'
)
# Get provider handler - pass user_id to automatically handle user-specific providers
# Get provider handler - pass user_id to automatically handle user-specific providers.
# Fall back to user_id=None (global config) when the provider isn't in the user's
# personal config; this lets admins inspect globally-configured providers.
from
aisbf.providers
import
get_provider_handler
from
aisbf.providers
import
get_provider_handler
try
:
try
:
handler
=
get_provider_handler
(
provider_key
,
user_id
=
current_user_id
)
handler
=
get_provider_handler
(
provider_key
,
user_id
=
current_user_id
)
except
ValueError
as
e
:
except
ValueError
:
return
JSONResponse
({
try
:
"success"
:
False
,
handler
=
get_provider_handler
(
provider_key
,
user_id
=
None
)
"error"
:
str
(
e
)
except
ValueError
as
e
:
},
status_code
=
404
)
return
JSONResponse
({
"success"
:
False
,
"error"
:
str
(
e
)
},
status_code
=
404
)
# Fetch models from provider
# Fetch models from provider
models_result
=
await
handler
.
get_models
()
models_result
=
await
handler
.
get_models
()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment