Corrected an issue, where the task was written into pending.data instead of completed.data, when marking it as done.