From e6808ef7a2d3a3b8c41265890a89441eacdfdf09 Mon Sep 17 00:00:00 2001 From: Nivedhith Date: Mon, 8 Jul 2024 16:18:41 +0530 Subject: [PATCH] Update usage of implemented suggestions --- examples/survey-feedback-analysis/main.bal | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/examples/survey-feedback-analysis/main.bal b/examples/survey-feedback-analysis/main.bal index 69067e5..1804765 100644 --- a/examples/survey-feedback-analysis/main.bal +++ b/examples/survey-feedback-analysis/main.bal @@ -32,14 +32,14 @@ final slack:Client slack = check new ({ public function main() returns error? { // Create a new channel for the survey - json|error createChannelResponse = check slack->/conversations\.create.post({name: channelName}); + json|error createChannelResponse = slack->/conversations\.create.post({name: CHANNEL_NAME}); if createChannelResponse is error { log:printError("Error creating the survey conversation: " + createChannelResponse.message()); return; } // Post a message to the conversation created and get the timestamp of the message - json|error sendMsgResponse = slack->/chat\.postMessage.post({channel: channelName, text: surveyRequestMessage}); + json|error sendMsgResponse = slack->/chat\.postMessage.post({channel: CHANNEL_NAME, text: SURVEY_REQUEST_MSG}); if sendMsgResponse is error { log:printError(sendMsgResponse.message()); return; @@ -47,7 +47,7 @@ public function main() returns error? { string messageTimestamp = check sendMsgResponse.message.ts; // Check for replies to the survey message - json|error repliesResponse = slack->/conversations\.replies({channel: channelName, ts: messageTimestamp}); + json|error repliesResponse = slack->/conversations\.replies({channel: CHANNEL_NAME, ts: messageTimestamp}); if repliesResponse is error { log:printError(repliesResponse.message()); return;