Skip to content

Commit

Permalink
fix: changed message pattern for basic-message (#950)
Browse files Browse the repository at this point in the history
* feat:migration script for did list

Signed-off-by: tipusinghaw <tipu.singh@ayanworks.com>

* feat:schema support for W3C

Signed-off-by: tipusinghaw <tipu.singh@ayanworks.com>

* fix: validation for null and empty string for did migration

Signed-off-by: tipusinghaw <tipu.singh@ayanworks.com>

* fix: changed message pattern for basic message

Signed-off-by: tipusinghaw <tipu.singh@ayanworks.com>

---------

Signed-off-by: tipusinghaw <tipu.singh@ayanworks.com>
  • Loading branch information
tipusinghaw authored and KulkarniShashank committed Sep 11, 2024
1 parent 67e5b07 commit ebb6ad3
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
8 changes: 4 additions & 4 deletions apps/agent-service/src/agent-service.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1891,13 +1891,13 @@ export class AgentServiceService {
}
}

async sendBasicMessage(questionPayload: IBasicMessage, url: string, orgId: string): Promise<object> {
async sendBasicMessage(messagePayload: IBasicMessage, url: string, orgId: string): Promise<object> {
try {
const getApiKey = await this.getOrgAgentApiKey(orgId);
const sendQuestionRes = await this.commonService
.httpPost(url, questionPayload, { headers: { authorization: getApiKey } })
const basicMessageRes = await this.commonService
.httpPost(url, messagePayload, { headers: { authorization: getApiKey } })
.then(async (response) => response);
return sendQuestionRes;
return basicMessageRes;
} catch (error) {
this.logger.error(`Error in sendBasicMessage in agent service : ${JSON.stringify(error)}`);
throw error;
Expand Down
2 changes: 1 addition & 1 deletion apps/api-gateway/src/connection/connection.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ export class ConnectionService extends BaseService {
basicMessageDto: BasicMessageDto
): Promise<object> {
try {
return this.sendNatsMessage(this.connectionServiceProxy, 'send-basic-message', basicMessageDto);
return this.sendNatsMessage(this.connectionServiceProxy, 'send-basic-message-on-connection', basicMessageDto);
} catch (error) {
throw new RpcException(error.response);
}
Expand Down
2 changes: 1 addition & 1 deletion apps/connection/src/connection.controller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ export class ConnectionController {
return this.connectionService.deleteConnectionRecords(orgId, userDetails);
}

@MessagePattern({ cmd: 'send-basic-message' })
@MessagePattern({ cmd: 'send-basic-message-on-connection' })
async sendBasicMessage(payload: {content: string, orgId: string, connectionId: string}): Promise<object> {
return this.connectionService.sendBasicMesage(payload);
}
Expand Down

0 comments on commit ebb6ad3

Please sign in to comment.