Opened 11 years ago
Last modified 9 months ago
#6555 new defect (bug)
Avatar upload dir filters set 'basedir' and 'baseurl' incorrectly
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Milestone: | Awaiting Contributions | Priority: | normal |
| Severity: | normal | Version: | |
| Component: | Core | Keywords: | needs-patch good-first-bug |
| Cc: | info@…, emaralive |
Description
bp_core_signup_avatar_upload_dir(), xprofile_avatar_upload_dir(), and groups_avatar_upload_dir() all filter 'upload_dir' to provide object-type-specific upload locations for avatars. The settings ultimately used by WP for the uploaded files come from the 'path' and 'subdir' values returned by these functions; 'basedir' and 'baseurl' are not used. However, these values *are* used to generate certain error messages (see eg the end of wp_upload_dir()), and we currently set them incorrectly, so that the error message gives an incorrect path (eg wp-content/uploads/group-avatars/123/group-avatars/123).