From fe64625fe9be28d2e27b85230764ff2d717f0171 Mon Sep 17 00:00:00 2001 From: Liz Hennessy Date: Fri, 13 Dec 2024 09:29:23 -0700 Subject: [PATCH 1/3] remove comments, make descriptions --- messages/src/schema.graphql | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/messages/src/schema.graphql b/messages/src/schema.graphql index ac6ee2e..a02e5b2 100644 --- a/messages/src/schema.graphql +++ b/messages/src/schema.graphql @@ -2,41 +2,41 @@ extend schema @link(url: "https://specs.apollo.dev/federation/v2.8", import: ["@key"]) type Query { - # Retrieve all conversations for the logged-in user + "Retrieve all conversations for the logged-in user" conversations: [Conversation] - # Retrieves your conversation with a given recipient + "Retrieves your conversation with a given recipient" conversation(recipientId: ID!): Conversation } type Mutation { - # Initiate a new conversation with a particular user + "Initiate a new conversation with a particular user" createConversation(recipientId: ID!): Conversation } type Conversation { id: ID! - # The messages belonging to the conversation + "The messages belonging to the conversation" messages: [Message] - # The timestamp from when the conversation was created + "The timestamp from when the conversation was created" createdAt: String! } type Message { id: ID! - # The text content of the message + "The text content of the message" text: String! - # The user that sent the message + "The user that sent the message" sentFrom: User! - # The user the message was sent to + "The user the message was sent to" sentTo: User! - # The timestamp of when the message was sent + "The timestamp of when the message was sent" sentTime: String } input NewMessageInput { - # The text content of the message + "The text content of the message" text: String! - # The ID of the conversation + "The ID of the conversation" conversationId: String! } From eaa0c7c2299710b35f0a2dc1a0dbab720424a531 Mon Sep 17 00:00:00 2001 From: Liz Hennessy Date: Fri, 13 Dec 2024 10:06:34 -0700 Subject: [PATCH 2/3] update from dictates to specifies --- router/router-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/router/router-config.yaml b/router/router-config.yaml index cbc1327..39e3713 100644 --- a/router/router-config.yaml +++ b/router/router-config.yaml @@ -1,4 +1,4 @@ -# This file dictates the settings the router should use when running +# This file specifies the settings the router should use when running supergraph: listen: 127.0.0.1:4000 include_subgraph_errors: @@ -11,4 +11,4 @@ headers: all: request: - propagate: - named: "Authorization" + named: 'Authorization' From c55c70f7615ff0c6b620d8592c9f07fe24fab884 Mon Sep 17 00:00:00 2001 From: Liz Hennessy Date: Fri, 13 Dec 2024 10:11:57 -0700 Subject: [PATCH 3/3] add comment indicating where to uncomment --- messages/src/resolvers/Mutation.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/messages/src/resolvers/Mutation.ts b/messages/src/resolvers/Mutation.ts index c60b404..e3be3a1 100644 --- a/messages/src/resolvers/Mutation.ts +++ b/messages/src/resolvers/Mutation.ts @@ -5,6 +5,7 @@ export const Mutation: Resolvers = { createConversation: async (_, { recipientId }, { dataSources, userId }) => { return dataSources.db.createNewConversation({ userId, recipientId }) }, + /* UNCOMMENT LINES 9-33 */ // sendMessage: async (_, { message }, { dataSources, userId }) => { // const { conversationId, text } = message; // const {