Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
chenpangpang
open-webui
Commits
b246c62d
Unverified
Commit
b246c62d
authored
Jan 22, 2024
by
Timothy Jaeryang Baek
Committed by
GitHub
Jan 22, 2024
Browse files
Merge pull request #545 from ollama-webui/openai-fix
fix: openai
parents
92d85ae2
d67c6329
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
1 deletion
+0
-1
backend/apps/openai/main.py
backend/apps/openai/main.py
+0
-1
No files found.
backend/apps/openai/main.py
View file @
b246c62d
...
@@ -95,7 +95,6 @@ async def proxy(path: str, request: Request, user=Depends(get_current_user)):
...
@@ -95,7 +95,6 @@ async def proxy(path: str, request: Request, user=Depends(get_current_user)):
body
=
json
.
dumps
(
body
)
body
=
json
.
dumps
(
body
)
except
json
.
JSONDecodeError
as
e
:
except
json
.
JSONDecodeError
as
e
:
print
(
"Error loading request body into a dictionary:"
,
e
)
print
(
"Error loading request body into a dictionary:"
,
e
)
raise
HTTPException
(
status_code
=
400
,
detail
=
"Invalid JSON in request body"
)
headers
=
{}
headers
=
{}
headers
[
"Authorization"
]
=
f
"Bearer
{
app
.
state
.
OPENAI_API_KEY
}
"
headers
[
"Authorization"
]
=
f
"Bearer
{
app
.
state
.
OPENAI_API_KEY
}
"
...
...
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