VideoChain-API / src /scheduler /getAllTasksForOwner.mts
jbilcke-hf's picture
jbilcke-hf HF staff
ready for release (sort of)
9571f2e
raw
history blame
403 Bytes
import { VideoTask } from "../types.mts"
import { getCompletedTasks } from "./getCompletedTasks.mts"
import { getPendingTasks } from "./getPendingTasks.mts"
export const getAllTasksForOwner = async (ownerId: string): Promise<VideoTask[]> => {
const pendingTasks = await getPendingTasks(ownerId)
const completedTasks = await getCompletedTasks(ownerId)
return [...pendingTasks, ...completedTasks]
}