Skip to content
This repository was archived by the owner on Dec 15, 2022. It is now read-only.

Commit 69adc7c

Browse files
authored
Merge branch 'master' into v0.0.4
2 parents ab9c628 + 68ab815 commit 69adc7c

File tree

5 files changed

+13
-2
lines changed

5 files changed

+13
-2
lines changed

core/TDSClient.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,10 +38,11 @@ export default class TDSClient {
3838
/**
3939
* Method for creating todoist resources (task, project, etc.). The resource type ond object are given by params.
4040
* If no params, creates a NO_CONTENT task
41+
* Returns true if all ok, then false.
4142
*/
4243
create({ type = "task" } = {}, ObjectFromType) {
4344
const TypeManager = new IManager(type, this.headers);
44-
TypeManager.create(ObjectFromType);
45+
return TypeManager.create(ObjectFromType);
4546
}
4647

4748
/**

core/managers/ProjectsManager.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ export default class ProjectsManager {
4040
let project = await getOneJSON(id, this.headers);
4141
return project;
4242
}
43+
4344
}
4445

4546
async function getAllJSON(headers) {

core/managers/TasksManager.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,13 @@ export default class TasksManager {
2222
return arrayTasks;
2323
}
2424

25+
/**
26+
* returns an array with all tasks JSON info
27+
*/
28+
async getAllJSON() {
29+
return await getAllJson(this.headers);
30+
}
31+
2532
/**
2633
* returns an array with all today tasks
2734
*/

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "todoist-rest-client",
3-
"version": "0.0.2",
3+
"version": "0.0.3",
44
"description": "A simple todoist-rest-api client",
55
"main": "index.js",
66
"type": "module",

readme.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,15 @@ A todoist rest API client with:
66

77
## Implemented Features
88

9+
910
- get Today Tasks (Names & JSON)
1011
- get a Task JSON by id
1112
- get All Tasks/Projects Names
1213
- get All Tasks/Projects JSON
1314
- create task/project (see examples)
1415
- complete task (see examples)
1516

17+
1618
I'll implement more features in the future like:
1719

1820
- new resources

0 commit comments

Comments
 (0)