From 384391add132e29258146d0781efb36554317438 Mon Sep 17 00:00:00 2001 From: "Wyatt J. Miller" Date: Sat, 24 Dec 2022 22:11:12 -0500 Subject: [PATCH] working file option --- BLL/CommitDetail.cs | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/BLL/CommitDetail.cs b/BLL/CommitDetail.cs index 4c33525..4194a87 100644 --- a/BLL/CommitDetail.cs +++ b/BLL/CommitDetail.cs @@ -5,6 +5,9 @@ public class CommitDetail private List? _authors; private SortedList? _commitDetails; private string _currentBranch; + private string? _outputOption; + private string? _branchOption; + private string? _tagOption; private string? _selectedDir; public List? Authors @@ -25,18 +28,28 @@ public class CommitDetail set { _currentBranch = value; } } - public string SelectedDir + public string? SelectedDir { get { return _selectedDir; } set { _selectedDir = value; } } - public CommitDetail(string dir) + public CommitDetail(string? dir) { + if (!String.IsNullOrEmpty(dir)) { + _selectedDir = dir; + } else { + _selectedDir = Directory.GetCurrentDirectory(); + } + _authors = new List(); _commitDetails = new SortedList(); _currentBranch = GetCurrentBranch(); - _selectedDir = Directory.Exists(dir) ? dir : Directory.GetCurrentDirectory(); + + // unused, might be used later for a refactor + _outputOption = null; + _branchOption = null; + _tagOption = null; } public void GetCurrentCommitsByName()