finished creating second level todos in todoist as checklists in habitica

This commit is contained in:
2020-04-10 23:02:02 -04:00
parent 49275681fd
commit 0aaf15a89d
9 changed files with 125 additions and 59 deletions

View File

@@ -11,7 +11,7 @@ namespace Habitica.Todoist.Integration.Services.Extensions
{
public static ChecklistItem ToHabiticaChecklistItem(this Item item, string habiticaId = null)
{
if (string.IsNullOrEmpty(item.Parent_Id))
if (!item.IsChild)
return null;
var checklistItem = new ChecklistItem
@@ -25,7 +25,7 @@ namespace Habitica.Todoist.Integration.Services.Extensions
public static Task ToHabiticaTask(this Item item, string habiticaId = null)
{
if (!string.IsNullOrEmpty(item.Parent_Id))
if (item.IsChild)
return null;
var taskTypeStr = Enum.GetName(typeof(TaskType), TaskType.Todo).ToLower();