Skip to content

Chapter7 - Administration #27

@pedrosmmc

Description

@pedrosmmc

Hi!
After finishing code to 7-15 and starting the app, the browser shows this error:

TypeError: orders is undefined
props
src/admin/OrdersConnector.js:16

13 | {
14 | options: (props) => ({variables: vars}),
15 | props: ({data: {loading, orders, refetch}}) => ({

16 | totalSize: loading ? 0 : orders.totalSize,
| ^ 17 | orders: loading ? [] : orders.orders,
18 | currentPage: vars.page,
19 | pageCount: loading ? 0 : Math.ceil(orders.totalSize / vars.pageSize),
...

I'm stuck in this part :( and need some help here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions