Skip to content

Commit

Permalink
feat: Prevent duplicate project name improvement
Browse files Browse the repository at this point in the history
  • Loading branch information
SyntaxGalaxy committed Oct 21, 2023
1 parent 4b6c871 commit 84b54dd
Showing 1 changed file with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -95,12 +95,16 @@ public boolean isNameAlreadyInUse(ArrayList<HashMap<String, Object>> projectList
if (projectList.get(i).containsKey("Path")) {
if (((File) projectList.get(i).get("Path"))
.getAbsolutePath()
.equals(new File(PROJECTS, name).getAbsolutePath())) {
.toLowerCase()
.equals(new File(PROJECTS, name).getAbsolutePath().toLowerCase())) {
isUsed = true;
}
}
if (projectList.get(i).containsKey("Project")) {
if (((Project) projectList.get(i).get("Project")).getProjectName().equals(name)) {
if (((Project) projectList.get(i).get("Project"))
.getProjectName()
.toLowerCase()
.equals(name.toLowerCase())) {
isUsed = true;
}
}
Expand Down

0 comments on commit 84b54dd

Please sign in to comment.