From d956e502dbddb60758bac0889157c826a3f5488b Mon Sep 17 00:00:00 2001 From: Kumar Vanshaj Date: Fri, 3 Apr 2026 20:17:51 +0530 Subject: [PATCH 1/3] Potential fix for code scanning alert no. 51: Assignment to constant Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> --- components/error-boundary.tsx | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/components/error-boundary.tsx b/components/error-boundary.tsx index 40aa66a..3c23980 100644 --- a/components/error-boundary.tsx +++ b/components/error-boundary.tsx @@ -127,9 +127,12 @@ export class ErrorBoundary extends Component { render() { const { hasError, error, errorInfo, showStackTrace } = this.state - const { children, fallback, level = 'component' } = this.props - const { hasError, error } = this.state - const { children, fallback, showDetails = process.env.NODE_ENV === 'development', level = 'component' } = this.props + const { + children, + fallback, + showDetails = process.env.NODE_ENV === 'development', + level = 'component', + } = this.props if (hasError && error) { if (fallback) { From 18e03150402fc0314e0dea094ceca6f4fd20c0be Mon Sep 17 00:00:00 2001 From: Kumar Vanshaj Date: Fri, 3 Apr 2026 20:20:59 +0530 Subject: [PATCH 2/3] Potential fix for code scanning alert no. 56: Unused variable, import, function or class Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> --- components/error-boundary.tsx | 1 - 1 file changed, 1 deletion(-) diff --git a/components/error-boundary.tsx b/components/error-boundary.tsx index 3c23980..e4bdf2c 100644 --- a/components/error-boundary.tsx +++ b/components/error-boundary.tsx @@ -130,7 +130,6 @@ export class ErrorBoundary extends Component { const { children, fallback, - showDetails = process.env.NODE_ENV === 'development', level = 'component', } = this.props From 0f163c19695f10c830657e0c3d566f97cb0b3a28 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Sun, 5 Apr 2026 15:00:00 +0000 Subject: [PATCH 3/3] Apply showDetails default in render*LevelError() methods Agent-Logs-Url: https://github.com/vectorMindsAI/vectorMindsAI-v0/sessions/507e7edb-8d99-4d06-a0c4-372d4355f8ac Co-authored-by: vanshaj2023 <151534626+vanshaj2023@users.noreply.github.com> --- components/error-boundary.tsx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/components/error-boundary.tsx b/components/error-boundary.tsx index e4bdf2c..becfe0a 100644 --- a/components/error-boundary.tsx +++ b/components/error-boundary.tsx @@ -156,7 +156,7 @@ export class ErrorBoundary extends Component { renderAppLevelError() { const { error, errorInfo, showStackTrace } = this.state - const { showDetails } = this.props + const { showDetails = process.env.NODE_ENV === 'development' } = this.props return (
@@ -227,7 +227,7 @@ export class ErrorBoundary extends Component { renderPageLevelError() { const { error, errorInfo, showStackTrace } = this.state - const { showDetails } = this.props + const { showDetails = process.env.NODE_ENV === 'development' } = this.props return (
@@ -290,7 +290,7 @@ export class ErrorBoundary extends Component { renderSectionLevelError() { const { error } = this.state - const { showDetails } = this.props + const { showDetails = process.env.NODE_ENV === 'development' } = this.props return ( @@ -317,7 +317,7 @@ export class ErrorBoundary extends Component { renderComponentLevelError() { const { error } = this.state - const { showDetails } = this.props + const { showDetails = process.env.NODE_ENV === 'development' } = this.props return (