Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
10/06/2015 11:53:33 PM (11 years ago)
Author:
imath
Message:

Allow class extending the BP_Attachment class to get the original WordPress upload dir within their upload_dir_filter() method.

To do so, you simply need to add the argument $upload_dir_filter_args to the array you use inside your constructor and set it to 1.

Props rittesh.patel

Fixes #6591

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/assets/attachment-extensions.php

    r9831 r10194  
    88                return parent::__construct( $args );
    99        }
     10
     11        public function upload_dir_filter( $upload_dir = array() ) {
     12                $this->original_upload_dir = $upload_dir;
     13
     14                return parent::upload_dir_filter( $upload_dir );
     15        }
    1016}
Note: See TracChangeset for help on using the changeset viewer.