Support » Plugin: Disable Blog » The REST API encountered an unexpected result when activating plugin

  • Thank you for an awesome ‘Go To’ plugin for most sites I do!

    I have noticed recently however that when activating the plugin, this message appears under ‘The REST API encountered an unexpected result‘ on the Site Health Screen:

    The REST API is one way WordPress, and other applications, communicate with the server. One example is the block editor screen, which relies on this to display, and save, your posts and pages.
    
    The REST API call gave the following unexpected result: (403) {"code":"rest_cannot_read_type","message":"Cannot view post type.","data":{"status":403}}.
    

    Is this something that can be fixed?

    Thanks!

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Joshua David Nelson

    (@joshuadnelson)

    Hey there! Glad you like the plugin, thanks for the kind words.

    I’ll take a look and get a fix as soon as possible.

    Anything unique about the site where you’re experiencing the error? Custom post types, etc?

    If you deactivate all other plugins and use a default theme, like TwentyTwenty, then activate this plugin, do you still encounter the error?

    Thread Starter whereverpanda

    (@whereverpanda)

    Hey Joshua,

    Thanks for your quick response!

    The site where I first saw the error does have custom post types and is quite busy and uses Oxygen Builder, ACF etc, but I went to one of my many simpler development sites that runs Elementor with the Hello Elementor theme with minimal plugins, and I checked the health screen and it said it on there as well.

    And in both cases, once I disabled the Disable Blog plugin, the message disappeared. I’ve also quickly installed a 100% clean version of the latest WordPress release, added only Disable Blog, activated it, and the message was there, deactivated and the message was gone. I still use it on all my sites, but I thought it might be something that can be fixed, in case it causes trouble somewhere down the line. I’m not a coder at all so I don’t know if it can cause issues, so I just thought I’d inform you.

    Thanks again!

    Plugin Author Joshua David Nelson

    (@joshuadnelson)

    Hey, thanks for getting back to me so quickly! That definitely helps, appreciate you checking that.

    I’ll work on a fix and get an update as soon as I can. It sounds like this shouldn’t creat any usability or functional issues with the site(s), but certainly better to have the Site Health not showing an error 😉

    Thread Starter whereverpanda

    (@whereverpanda)

    Thanks man – Much appreciated!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘The REST API encountered an unexpected result when activating plugin’ is closed to new replies.