Skip to content

Commit

Permalink
🐛 Fix 304 Error
Browse files Browse the repository at this point in the history
  • Loading branch information
luoshuijs committed Mar 26, 2024
1 parent 8438e6d commit a0b1a5b
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions crates/openai/src/serve/proxy/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,12 @@ pub(crate) fn header_convert(
headers.insert(header::ORIGIN, header::HeaderValue::from_static(origin));
headers.insert(header::REFERER, header::HeaderValue::from_static(origin));

headers.insert(
header::COOKIE,
header::HeaderValue::from_str("__Secure-next-auth.callback-url=https%3A%2F%2Fchat.openai.com")
.map_err(ResponseError::InternalServerError)?,
);

jar.iter()
.filter(|c| {
let name = c.name().to_lowercase();
Expand Down

0 comments on commit a0b1a5b

Please sign in to comment.