refactor logic into another habitica service and modified license

This commit is contained in:
2020-03-25 18:40:56 -04:00
parent 9ecc9829f0
commit ca46f0f159
7 changed files with 182 additions and 106 deletions

View File

@@ -18,12 +18,12 @@ namespace Habitica.Todoist.Integration.Services
private string userId { get; set; }
private string latestSyncToken { get; set; } = string.Empty;
public TodoistIntegrationService(TodoistServiceClient todoistClient,
TableStorageClient storageClient,
public TodoistIntegrationService(string todoistApiKey,
string storageConnectionString,
string userId)
{
this.todoistClient = todoistClient;
this.storageClient = storageClient;
this.todoistClient = new TodoistServiceClient(todoistApiKey);
this.storageClient = new TableStorageClient(storageConnectionString);
this.userId = userId;
}