From 1e63f6a274d8454ae250d45dbe538288854ea25f Mon Sep 17 00:00:00 2001 From: Sebastien Marichal Date: Fri, 31 Jan 2025 15:47:52 +0100 Subject: [PATCH] Modify rule S4487: Fix error in code example (#4644) --- rules/S4487/csharp/rule.adoc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/rules/S4487/csharp/rule.adoc b/rules/S4487/csharp/rule.adoc index ecccd1c528..f27efe8adf 100644 --- a/rules/S4487/csharp/rule.adoc +++ b/rules/S4487/csharp/rule.adoc @@ -13,13 +13,13 @@ public class Rectangle { this.length = length; this.width = width; - } + } public int Surface { get { - return length * width; + return length * length; } } } @@ -56,4 +56,4 @@ public class Rectangle * CWE - https://cwe.mitre.org/data/definitions/563[CWE-563 - Assignment to Variable without Use ('Unused Variable')] -include::../rspecator.adoc[] \ No newline at end of file +include::../rspecator.adoc[]