mirror of
https://github.com/toeverything/AFFiNE.git
synced 2025-01-02 07:24:14 +03:00
fix(core): gql file upload (#9134)
This commit is contained in:
parent
152a406ced
commit
76f2c31e46
@ -138,7 +138,7 @@ module.exports = {
|
||||
if (schema.getType(type)?.name === 'Upload') return true;
|
||||
const typeDef = schema.getType(type);
|
||||
const fields = typeDef.getFields?.();
|
||||
if (!fields || !fields.length) return false;
|
||||
if (!fields || typeof fields !== 'object') return false;
|
||||
for (let field of Object.values(fields)) {
|
||||
let type = field.type;
|
||||
while (type.ofType) {
|
||||
|
@ -188,7 +188,7 @@ export const createCopilotMessageMutation = {
|
||||
id: 'createCopilotMessageMutation' as const,
|
||||
operationName: 'createCopilotMessage',
|
||||
definitionName: 'createCopilotMessage',
|
||||
containsFile: false,
|
||||
containsFile: true,
|
||||
query: `
|
||||
mutation createCopilotMessage($options: CreateChatMessageInput!) {
|
||||
createCopilotMessage(options: $options)
|
||||
|
Loading…
Reference in New Issue
Block a user