public LocalUserStore(string folderName, LocalSubscriber localSubscriber) { var appdataDir = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "SnippetStudio"); appdataDir = Path.Combine(appdataDir, folderName); Directory.CreateDirectory(appdataDir); _dataPath = Path.Combine(appdataDir, "Users.json"); _items = GetItems(); _subscriber = localSubscriber; }
public LocalSnippetStore(string folderName, LocalSubscriber localSubscriber) { if (Path.IsPathRooted(folderName)) { _dataPath = folderName; } else { var appdataDir = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "SnippetStudio"); appdataDir = Path.Combine(appdataDir, folderName); Directory.CreateDirectory(appdataDir); _dataPath = appdataDir; } _items = GetItems(); _subscriber = localSubscriber; }