Getting Wrong Data via WPGRAPHQL Query

My WordPress Menu:

I am getting Child Page twice, once it is shown as a child page and another time it is displayed as a Level one Menu item, It must not show as a Level 1 menu page.

Is it a bug in the plugin or I am doing it the wrong way????
My WPGRAPHQL Query

query mainMenu {
  menu(idType: NAME, id: "main menu") {
    menuItems {
      edges {
        node {
          id
          uri
          title
          target
          label
          childItems {
            edges {
              node {
                id
                uri
                title
                target
                label
                parentId
              }
            }
          }
        }
      }
    }
  }
}

WPGRAPHQL Query RESULT

{
  "data": {
    "menu": {
      "menuItems": {
        "edges": [
          {
            "node": {
              "id": "cG9zdDozNA==",
              "uri": "/",
              "title": "home link",
              "target": null,
              "label": "Home",
              "childItems": {
                "edges": []
              }
            }
          },
          {
            "node": {
              "id": "cG9zdDozMA==",
              "uri": "/about-us/",
              "title": null,
              "target": null,
              "label": "About Us",
              "childItems": {
                "edges": [
                  {
                    "node": {
                      "id": "cG9zdDo2MQ==",
                      "uri": "/child-page/",
                      "title": null,
                      "target": null,
                      "label": "Child page",
                      "parentId": "cG9zdDozMA=="
                    }
                  }
                ]
              }
            }
          },
          {
            "node": {
              "id": "cG9zdDo2MQ==",
              "uri": "/child-page/",
              "title": null,
              "target": null,
              "label": "Child page",
              "childItems": {
                "edges": []
              }
            }
          },
          {
            "node": {
              "id": "cG9zdDoyOA==",
              "uri": "/portfolio/",
              "title": null,
              "target": null,
              "label": "Portfolio",
              "childItems": {
                "edges": []
              }
            }
          },
          {
            "node": {
              "id": "cG9zdDoyOQ==",
              "uri": "/services/",
              "title": null,
              "target": null,
              "label": "Services",
              "childItems": {
                "edges": []
              }
            }
          },
          {
            "node": {
              "id": "cG9zdDoyNw==",
              "uri": "/contact-us/",
              "title": null,
              "target": null,
              "label": "Contact Us",
              "childItems": {
                "edges": []
              }
            }
          },
          {
            "node": {
              "id": "cG9zdDozNw==",
              "uri": "/policy/",
              "title": null,
              "target": null,
              "label": "Policy",
              "childItems": {
                "edges": []
              }
            }
          }
        ]
      }
    }
  },
  "extensions": {
    "debug": [
      {
        "type": "DEBUG_LOGS_INACTIVE",
        "message": "GraphQL Debug logging is not active. To see debug logs, GRAPHQL_DEBUG must be enabled."
      }
    ]
  }
}

Expected Result

{
  "data": {
    "menu": {
      "menuItems": {
        "edges": [
          {
            "node": {
              "id": "cG9zdDozNA==",
              "uri": "/",
              "title": "home link",
              "target": null,
              "label": "Home",
              "childItems": {
                "edges": []
              }
            }
          },
          {
            "node": {
              "id": "cG9zdDozMA==",
              "uri": "/about-us/",
              "title": null,
              "target": null,
              "label": "About Us",
              "childItems": {
                "edges": [
                  {
                    "node": {
                      "id": "cG9zdDo2MQ==",
                      "uri": "/child-page/",
                      "title": null,
                      "target": null,
                      "label": "Child page",
                      "parentId": "cG9zdDozMA=="
                    }
                  }
                ]
              }
            }
          },
          {
            "node": {
              "id": "cG9zdDoyOA==",
              "uri": "/portfolio/",
              "title": null,
              "target": null,
              "label": "Portfolio",
              "childItems": {
                "edges": []
              }
            }
          },
          {
            "node": {
              "id": "cG9zdDoyOQ==",
              "uri": "/services/",
              "title": null,
              "target": null,
              "label": "Services",
              "childItems": {
                "edges": []
              }
            }
          },
          {
            "node": {
              "id": "cG9zdDoyNw==",
              "uri": "/contact-us/",
              "title": null,
              "target": null,
              "label": "Contact Us",
              "childItems": {
                "edges": []
              }
            }
          },
          {
            "node": {
              "id": "cG9zdDozNw==",
              "uri": "/policy/",
              "title": null,
              "target": null,
              "label": "Policy",
              "childItems": {
                "edges": []
              }
            }
          }
        ]
      }
    }
  },
  "extensions": {
    "debug": [
      {
        "type": "DEBUG_LOGS_INACTIVE",
        "message": "GraphQL Debug logging is not active. To see debug logs, GRAPHQL_DEBUG must be enabled."
      }
    ]
  }
}

 

This site will teach you how to build a WordPress website for beginners. We will cover everything from installing WordPress to adding pages, posts, and images to your site. You will learn how to customize your site with themes and plugins, as well as how to market your site online.

Buy WordPress Transfer