Update getAll() method to include relations.

This commit is contained in:
themodrnhakr 2025-09-27 14:20:39 -05:00
parent 0331042b8b
commit b68935a11e

View File

@ -12,7 +12,11 @@ class TasksService {
public async getAll() {
logger.info("Fetching all task records...");
try {
const result = await this.db.query.tasks.findMany();
const result = await this.db.query.tasks.findMany({
with: {
type: true,
},
});
logger.debug(`Found ${result.length} records.`);
return result;
} catch (e) {