Skip to content

Commit 5984882

Browse files
committed
fix: change log statements to error logs in connection utility
1 parent 68d8513 commit 5984882

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@tsmztech/mcp-server-salesforce",
3-
"version": "0.0.4",
3+
"version": "0.0.5",
44
"description": "A Salesforce connector MCP Server.",
55
"main": "dist/index.js",
66
"types": "dist/index.d.ts",

src/utils/connection.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ async function getSalesforceOrgInfo(): Promise<SalesforceCLIResponse> {
1515
try {
1616
const command = 'sf org display --json';
1717
const cwdLog = process.cwd();
18-
console.log(`Executing Salesforce CLI command: ${command} in directory: ${cwdLog}`);
18+
console.error(`Executing Salesforce CLI command: ${command} in directory: ${cwdLog}`);
1919

2020
// Use execAsync and handle both success and error cases
2121
let stdout = '';
@@ -154,7 +154,7 @@ export async function createSalesforceConnection(config?: ConnectionConfig) {
154154
return conn;
155155
} else if (connectionType === ConnectionType.Salesforce_CLI) {
156156
// Salesforce CLI authentication using sf org display
157-
console.log('Connecting to Salesforce using Salesforce CLI authentication');
157+
console.error('Connecting to Salesforce using Salesforce CLI authentication');
158158

159159
// Execute sf org display --json command
160160
const orgInfo = await getSalesforceOrgInfo();
@@ -165,8 +165,8 @@ export async function createSalesforceConnection(config?: ConnectionConfig) {
165165
accessToken: orgInfo.result.accessToken
166166
});
167167

168-
console.log(`Connected to Salesforce org: ${orgInfo.result.username} (${orgInfo.result.alias || 'No alias'})`);
169-
168+
console.error(`Connected to Salesforce org: ${orgInfo.result.username} (${orgInfo.result.alias || 'No alias'})`);
169+
170170
return conn;
171171
} else {
172172
// Default: Username/Password Flow with Security Token

0 commit comments

Comments
 (0)