mirror of
				https://github.com/ChatGPTNextWeb/ChatGPT-Next-Web.git
				synced 2025-11-04 16:23:41 +08:00 
			
		
		
		
	fix(#5378): default plugin ids to empty array
This commit is contained in:
		@@ -203,7 +203,7 @@ export class ClaudeApi implements LLMApi {
 | 
			
		||||
      const [tools, funcs] = usePluginStore
 | 
			
		||||
        .getState()
 | 
			
		||||
        .getAsTools(
 | 
			
		||||
          useChatStore.getState().currentSession().mask?.plugin as string[],
 | 
			
		||||
          useChatStore.getState().currentSession().mask?.plugin || [],
 | 
			
		||||
        );
 | 
			
		||||
      return stream(
 | 
			
		||||
        path,
 | 
			
		||||
 
 | 
			
		||||
@@ -125,7 +125,7 @@ export class MoonshotApi implements LLMApi {
 | 
			
		||||
        const [tools, funcs] = usePluginStore
 | 
			
		||||
          .getState()
 | 
			
		||||
          .getAsTools(
 | 
			
		||||
            useChatStore.getState().currentSession().mask?.plugin as string[],
 | 
			
		||||
            useChatStore.getState().currentSession().mask?.plugin || [],
 | 
			
		||||
          );
 | 
			
		||||
        return stream(
 | 
			
		||||
          chatPath,
 | 
			
		||||
 
 | 
			
		||||
@@ -244,7 +244,7 @@ export class ChatGPTApi implements LLMApi {
 | 
			
		||||
        const [tools, funcs] = usePluginStore
 | 
			
		||||
          .getState()
 | 
			
		||||
          .getAsTools(
 | 
			
		||||
            useChatStore.getState().currentSession().mask?.plugin as string[],
 | 
			
		||||
            useChatStore.getState().currentSession().mask?.plugin || [],
 | 
			
		||||
          );
 | 
			
		||||
        // console.log("getAsTools", tools, funcs);
 | 
			
		||||
        stream(
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user