Skip to content

Commit

Permalink
fix duplicate check with project paths (#5)
Browse files Browse the repository at this point in the history
  • Loading branch information
nothingTVatYT committed Jan 17, 2024
1 parent f4f6444 commit e082644
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Seed/ViewModels/ProjectsViewModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,8 @@ private async void AddProject_Clicked()
});
if (file is null) return;

var duplicate = _projectManager.Projects.Any(x => file.Path.ToString().Contains(x.Path));
var filePath = file.Path.LocalPath[..^(file.Name.Length+1)];
var duplicate = _projectManager.Projects.Any(x => filePath.Equals(x.Path));
if (duplicate)
{
var box = MessageBoxManager.GetMessageBoxStandard(
Expand Down

0 comments on commit e082644

Please sign in to comment.