Skip to content

Compatibilty with WP 5.5 #71

Description

@adriacobo

The rest_routes:
pagantis/v1/logs/(?P\w+)/(?P\d+)/(?P\d+)
pagantis/v1/configController/(?P\w+)
pagantis/v1/api/(?P\w+)/(?P\w+)/(?P\w+)

must have a permision_callback parameter. If this routes are public the value for the parameter can be "__return_true", if not only having a

 if ( ! is_user_logged_in() ) {
    return new WP_Error( 'rest_not_logged_in', 'You are not currently logged in.', array( 'status' => 401 ) );
  }

must be enough.

Also I can do a Pull Request with this code.
Thanks a lot!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions