Chore: Fix crowdin task cleanup (#105690)
* fix cleanup of project tasks * fix task cleanup
This commit is contained in:
@@ -26,7 +26,8 @@ const { tasksApi } = new crowdin(credentials);
|
|||||||
const tasks = await listTasks(PROJECT_ID);
|
const tasks = await listTasks(PROJECT_ID);
|
||||||
for (const task of tasks) {
|
for (const task of tasks) {
|
||||||
const { id, status, progress } = task.data;
|
const { id, status, progress } = task.data;
|
||||||
if (status === 'todo' && progress.done === progress.total) {
|
console.log(`Processing task ${id} with status ${status} and progress ${progress.done}/${progress.total}`);
|
||||||
|
if (status === 'in_progress' && progress.done === progress.total) {
|
||||||
console.log(`Marking task ${id} as done`);
|
console.log(`Marking task ${id} as done`);
|
||||||
await markTaskAsDone(PROJECT_ID, id);
|
await markTaskAsDone(PROJECT_ID, id);
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user