Make waspc/todoApp return tasks in consistent order

This commit is contained in:
Filip Sodić 2022-06-13 15:23:09 +02:00
parent b64890b493
commit 57606c74e4

View File

@ -9,7 +9,10 @@ export const getTasks = async (args, context) => {
const Task = context.entities.Task
const tasks = await Task.findMany(
{ where: { user: { id: context.user.id } } }
{
where: { user: { id: context.user.id } },
orderBy: { id: 'asc' },
}
)
return tasks
}