Skip to content

Commit

Permalink
Testing out the cached build
Browse files Browse the repository at this point in the history
  • Loading branch information
infomiho committed Oct 31, 2024
1 parent 0f5ab97 commit 9b692dc
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/tasks/queries.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,14 @@ export const getTasks = (async (_args, context) => {
orderBy: { id: "asc" },
});
return tasks.map((task) => {
task.description = task.description.toUpperCase();
task.description = toEveryOtherUppercase(task.description);
return task;
});
}) satisfies GetTasks<void, Task[]>;

function toEveryOtherUppercase(str: string): string {
return str
.split("")
.map((char, index) => (index % 2 === 0 ? char.toUpperCase() : char))
.join("");
}

0 comments on commit 9b692dc

Please sign in to comment.