Spot the bug in the relationship resolver

from GraphQL
Node 24 intermediate 4 min 1 issue to find

Find the data-access problem in this generated relationship resolver.

JavaScript
const resolvers = {
  Query: {
    orders: (_root, _args, { db }) => db.orders.list(),
  },
  Order: {
    customer: (order, _args, { db }) =>
      db.customers.findById(order.customerId),
  },
};
Open in playground
Report an error