Skip to content

Refactor Api Common [Server Side] [Console Log]#3424

Merged
Dean-YZG merged 3 commits intoChatGPTNextWeb:mainfrom
H0llyW00dzZ:serverrside
Mar 28, 2024
Merged

Refactor Api Common [Server Side] [Console Log]#3424
Dean-YZG merged 3 commits intoChatGPTNextWeb:mainfrom
H0llyW00dzZ:serverrside

Conversation

@H0llyW00dzZ
Copy link
Contributor

@H0llyW00dzZ H0llyW00dzZ commented Dec 1, 2023

  • [+] refactor(common.ts): remove unnecessary console.log for [Org ID] in requestOpenai function
  • [+] refactor(common.ts): conditionally delete OpenAI-Organization header from response if [Org ID] is not set up in ENV

Note

This one is much better now. depends of environment variables

H0llyW00dzZ and others added 3 commits December 1, 2023 19:49
- [+] refactor(common.ts): remove unnecessary console.log for [Org ID] in requestOpenai function
- [+] refactor(common.ts): conditionally delete OpenAI-Organization header from response if [Org ID] is not set up in ENV
- [+] fix(common.ts): improve handling of OpenAI-Organization header
 - Check if serverConfig.openaiOrgId is defined and not an empty string
 - Log the value of openaiOrganizationHeader if present, otherwise log that the header is not present
 - Conditionally delete the OpenAI-Organization header from the response if [Org ID] is undefined or empty (not setup in ENV)
@vercel
Copy link

vercel bot commented Mar 28, 2024

@Dean-YZG is attempting to deploy a commit to the NextChat Team on Vercel.

A member of the Team first needs to authorize it.

@github-actions
Copy link
Contributor

Your build has completed!

Preview deployment

@Dean-YZG Dean-YZG merged commit 57026f6 into ChatGPTNextWeb:main Mar 28, 2024
@H0llyW00dzZ H0llyW00dzZ deleted the serverrside branch March 28, 2024 03:43
gaogao1030 pushed a commit to gaogao1030/ChatGPT-Next-Web that referenced this pull request May 16, 2024
Refactor Api Common [Server Side] [Console Log]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants