Skip to content

Commit

Permalink
Eliminate hard-coded passwords
Browse files Browse the repository at this point in the history
  • Loading branch information
trick-treat committed Nov 10, 2023
1 parent 8787bc2 commit 792b7a1
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/main/java/com/Main.java
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import java.util.logging.Logger;

public class Main {
private static final String password = "123";
// private static final String password = "123";
private static final Logger logger = Logger.getLogger(Main.class.getName());

public int add(int a, int b) {
Expand All @@ -29,7 +29,7 @@ public static void main(String[] args) {

// Test cases
System.out.println("Test Case 1 (5 + 5): " + calculator.add(5, 5));
System.out.println("Test Case 2 (Integer.MAX_VALUE + 1):" + password);
// System.out.println("Test Case 2 (Integer.MAX_VALUE + 1):" + password);
try {
calculator.add(Integer.MAX_VALUE, 1);
} catch (Exception e) {
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/com/ResourceLeakExample.java
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@ public class ResourceLeakExample {

public static void main(String[] args) {
String password;
password = "12345";
System.out.println(password);
// password = "12345";
// System.out.println(password);
}

}
Binary file modified target/classes/com/ResourceLeakExample.class
Binary file not shown.

0 comments on commit 792b7a1

Please sign in to comment.