mirror of
https://github.com/Yidadaa/ChatGPT-Next-Web.git
synced 2025-08-06 22:59:07 +08:00
fix model leak issue
This commit is contained in:
@@ -8,7 +8,7 @@ import {
|
||||
import { prettyObject } from "@/app/utils/format";
|
||||
import { NextRequest, NextResponse } from "next/server";
|
||||
import { auth } from "@/app/api/auth";
|
||||
import { isModelAvailableInServer } from "@/app/utils/model";
|
||||
import { isModelNotavailableInServer } from "@/app/utils/model";
|
||||
|
||||
const serverConfig = getServerSideConfig();
|
||||
|
||||
@@ -88,7 +88,7 @@ async function request(req: NextRequest) {
|
||||
|
||||
// not undefined and is false
|
||||
if (
|
||||
isModelAvailableInServer(
|
||||
isModelNotavailableInServer(
|
||||
serverConfig.customModels,
|
||||
jsonBody?.model as string,
|
||||
ServiceProvider.ByteDance as string,
|
||||
|
Reference in New Issue
Block a user