~canonical-sysadmins/wordpress/upstream

« back to all changes in this revision

Viewing changes to wp-includes/rest-api.php

  • Committer: Barry Price
  • Date: 2019-10-16 07:26:33 UTC
  • Revision ID: barry.price@canonical.com-20191016072633-1jg1zi7uh0fpem6g
new upstream release 5.1.3

Show diffs side-by-side

added added

removed removed

Lines of Context:
587
587
                header( 'Access-Control-Allow-Origin: ' . $origin );
588
588
                header( 'Access-Control-Allow-Methods: OPTIONS, GET, POST, PUT, PATCH, DELETE' );
589
589
                header( 'Access-Control-Allow-Credentials: true' );
590
 
                header( 'Vary: Origin' );
 
590
                header( 'Vary: Origin', false );
 
591
        } elseif ( ! headers_sent() && 'GET' === $_SERVER['REQUEST_METHOD'] && ! is_user_logged_in() ) {
 
592
                header( 'Vary: Origin', false );
591
593
        }
592
594
 
593
595
        return $value;