简体   繁体   中英

gatsby"permission to view this setting." email

When working with Gatsby and the GraphiQL web console, I get the following error in the output from a query that accesses the site email:

Sorry, you do not have permission to view this setting.

This was after updating to the latest version of WPGraphQL v1.9.0 (although it may have been in previous versions).

My setup:

  • NON-PUBLIC WordPress - I just run it locally in a docker instance.
  • Gatsby with gatsby-source-wordpress to load & generate my static site
  • Netlify publish of the static site

So hence there is zero need for any actual auth to Wordpress.

Turns out the easiest fix was to just toggle the icon in the GraphiQL web console to use the logged in user to run the query.

在此处输入图像描述

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM