const res = await db.query.postsTable.findMany({
with: {
user: true,
},
where: (posts, { eq, and }) =>
and(
eq(posts.done, true), //<- This works
eq(posts.user.public, true) // <- This not
),
});
const res = await db.query.postsTable.findMany({
with: {
user: true,
},
where: (posts, { eq, and }) =>
and(
eq(posts.done, true), //<- This works
eq(posts.user.public, true) // <- This not
),
});