Skip to content

Commit 2c07e89

Browse files
author
flowcore-platform
committed
fix: prevent error information leakage in data sources page
- Changed console.error to log only error.message instead of full error object - Prevents potential exposure of sensitive internal details and stack traces - Implements secure error logging as recommended by security validation - Resolves high-risk security issue identified in PR validation
1 parent e36b603 commit 2c07e89

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

app/data-sources/page.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ export default async function DataSourcesPage() {
1717
try {
1818
workspaceId = await getWorkspaceForUser(session.user.id)
1919
} catch (error) {
20-
console.error("Failed to fetch workspace:", error)
20+
console.error("Failed to fetch workspace:", error instanceof Error ? error.message : "Unknown error")
2121
}
2222
}
2323

@@ -33,7 +33,7 @@ export default async function DataSourcesPage() {
3333
try {
3434
dataSources = await dataSourceService.listDataSources(workspaceId, session.user.accessToken)
3535
} catch (error) {
36-
console.error("Failed to fetch data sources:", error)
36+
console.error("Failed to fetch data sources:", error instanceof Error ? error.message : "Unknown error")
3737
}
3838
}
3939

0 commit comments

Comments
 (0)