Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
02/15/2018 03:52:40 PM (9 years ago)
Author:
espellcaste
Message:

Make use of bp_is_post_request() instead of hardcoding POST verifications directly.

BuddyPress is not making use of the bp_is_post_request() in several ajax scenarios to confirm if the post request is indeed a POST request. Instead, it is hardcoding the check directly. This change updates those places making use of this function.

Props DjPaul

Fixes #7684

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-xprofile/bp-xprofile-actions.php

    r10825 r11858  
    5555
    5656        // Bail if not a POST action.
    57         if ( 'POST' !== strtoupper( $_SERVER['REQUEST_METHOD'] ) ) {
     57        if ( ! bp_is_post_request() ) {
    5858                return;
    5959        }
Note: See TracChangeset for help on using the changeset viewer.