Skip to content

Commit

Permalink
Tweak - Add filter to change profile picture upload directory.
Browse files Browse the repository at this point in the history
  • Loading branch information
iamprazol committed Oct 10, 2023
1 parent 58719cf commit a8aeee3
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.txt
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
* Dev - Compatibility for form fields integration on woo commerce product page.
* Tweak - Save the user IP on the user meta.
* Tweak - Onboarding last page design changes.
* Tweak - Add filter to change profile picture upload directory.
* Fix - Admin email not being delivered.
* Fix - Wrong escaping done in redirect_url parameter.
* Fix - Grammatical typo for unique validation message.
Expand Down
2 changes: 1 addition & 1 deletion includes/functions-ur-core.php
Original file line number Diff line number Diff line change
Expand Up @@ -3105,7 +3105,7 @@ function ur_get_user_roles( $user_id ) {
*/
function ur_upload_profile_pic( $valid_form_data, $user_id ) {
$attachment_id = array();
$upload_path = UR_UPLOAD_PATH . 'profile-pictures'; /*Get path of upload dir of User Registration for profile pictures*/
$upload_path = apply_filters( 'user_registration_profile_pic_upload_url', UR_UPLOAD_PATH . 'profile-pictures' ); /*Get path of upload dir of WordPress*/

// Checks if the upload directory exists and create one if not.
if ( ! file_exists( $upload_path ) ) {
Expand Down
1 change: 1 addition & 0 deletions readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -377,6 +377,7 @@ We are ready to assist you! You can contact us through the WordPress.org help fo
* Dev - Compatibility for form fields integration on woo commerce product page.
* Tweak - Save the user IP on the user meta.
* Tweak - Onboarding last page design changes.
* Tweak - Add filter to change profile picture upload directory.
* Fix - Admin email not being delivered.
* Fix - Wrong escaping done in redirect_url parameter.
* Fix - Grammatical typo for unique validation message.
Expand Down

0 comments on commit a8aeee3

Please sign in to comment.