Skip to content

Conversation

rkaiser0324
Copy link

@rkaiser0324 rkaiser0324 commented Jan 20, 2021

As of WordPress 5.5.0 the permission_callback is required, or you get this:

Notice: register_rest_route was called incorrectly. The REST API route definition for rollbar/v1/test-php-logging is missing the required permission_callback argument. For REST API routes that are intended to be public, use __return_true as the permission callback. Please see Debugging in WordPress for more information. (This message was added in version 5.5.0.)

This fixes that.

@brandoncc
Copy link

Please merge this!

Copy link

@bishopb bishopb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your contribution, @rkaiser0324! Manual testing confirms fix for WordPress 5.5+ without impact to behavior on WordPress 5.0 to 5.4. We'll forgo a test on this specific change as it's documented as part of the WordPress plugin specification.

@bishopb bishopb merged commit 2892219 into rollbar:master Nov 17, 2021
@bishopb bishopb added this to the 2.6.2 milestone Nov 17, 2021
@rkaiser0324 rkaiser0324 deleted the fix/register-rest-route branch January 9, 2023 23:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants