Make WordPress Core

Ticket #42303: 42303.1.diff

File 42303.1.diff, 846 bytes (added by schlessera, 7 years ago)

'Sorry, you are not allowed to manage post statuses.'

  • src/wp-includes/rest-api/endpoints/class-wp-rest-post-statuses-controller.php

    diff --git src/wp-includes/rest-api/endpoints/class-wp-rest-post-statuses-controller.php src/wp-includes/rest-api/endpoints/class-wp-rest-post-statuses-controller.php
    index e2cce55b65..2d3885971b 100644
    class WP_REST_Post_Statuses_Controller extends WP_REST_Controller { 
    8181                                        return true;
    8282                                }
    8383                        }
    84                         return new WP_Error( 'rest_cannot_view', __( 'Sorry, you are not allowed to edit posts in this post type.' ), array( 'status' => rest_authorization_required_code() ) );
     84                        return new WP_Error( 'rest_cannot_view', __( 'Sorry, you are not allowed to manage post statuses.' ), array( 'status' => rest_authorization_required_code() ) );
    8585                }
    8686
    8787                return true;