Changeset 13541
- Timestamp:
- 08/03/2023 05:23:18 AM (2 years ago)
- File:
-
- 1 edited
-
trunk/src/bp-core/bp-core-avatars.php (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bp-core/bp-core-avatars.php
r13497 r13541 1624 1624 */ 1625 1625 function bp_core_get_upload_dir( $type = 'upload_path' ) { 1626 $bp = buddypress(); 1626 $bp = buddypress(); 1627 $retval = ''; 1627 1628 1628 1629 switch ( $type ) { … … 1640 1641 1641 1642 default : 1642 return false;1643 return $retval; 1643 1644 1644 1645 break; … … 1668 1669 } 1669 1670 1670 // Directory does not exist and cannot be created. 1671 if ( ! empty( $upload_dir['error'] ) ) { 1672 $retval = ''; 1673 1674 } else { 1675 $retval = $upload_dir[$key]; 1671 // Upload directory exists. 1672 if ( isset( $upload_dir[ $key ] ) ) { 1673 $retval = $upload_dir[ $key ]; 1676 1674 1677 1675 // If $key is 'baseurl', check to see if we're on SSL 1678 1676 // Workaround for WP13941, WP15928, WP19037. 1679 if ( $key == 'baseurl' && is_ssl() ) {1677 if ( $key === 'baseurl' && is_ssl() ) { 1680 1678 $retval = str_replace( 'http://', 'https://', $retval ); 1681 1679 } 1682 1680 } 1683 1684 1681 } 1685 1682
Note: See TracChangeset
for help on using the changeset viewer.